About this question
Hard · architecture & logic · Quant Developer interview question · c++, design-pattern, algorithms, finance
Deterministic replay engines are fundamental to high-frequency trading, enabling the exact reproduction of internal states and strategy outputs from historical logs. This capability is essential for debugging production incidents and backtesting strategies against out-of-order market data. Task Implement a replay engine for a momentum-based trading strategy that processes a batch of raw, potentially out-of-order events. The engine must sort the events, maintain a decaying momentum state, and ge