Questions / Quant development, Streaming market data

A duplicate trade arrives

Applied, about 6 minutes. Question D027.

Active volume is 500 shares and already includes event E7 of 40 shares. E7 is replayed twice more. Under exactly-once aggregation, what is the volume?

Answer it in the app It's free. You get hints, a second try if you miss, and a follow-up question.

Show the answer and worked solution

Answer: 500 shares

  1. E7 is already counted once.
  2. Both replays carry the same immutable ID, so they add nothing.
  3. Volume stays at 500.

Interview shortcut. Replays of a counted ID add nothing.

Takeaway. Same event ID: count it once.

In the app this has a follow-up where one thing about the setup changes. Try the follow-up.

More streaming market data questions