What an Order Book Really Is
The order book is the one domain problem these firms ask that no general platform teaches. It has been set as a multi-day take-home graded on roughly thirty hidden tests, as an aggregation question inside a timed assessment, as a matching problem on an auto-graded platform, and as a string-parsing problem with a heavy debugging round behind it. Four firms, four formats, one structure.
If you want the trading side of what a book means, that is how an order book works in the markets course. This section is about implementing one.
As a data structure
A book is two sorted collections of price levels, bids descending and asks ascending, where each level holds a queue of orders in arrival order. That is the whole model, and every design decision follows from which operations have to be fast.
The rest of this lesson is for subscribers
Unlock every lesson in Programming for Quantitative Developers, and every other premium course.
Subscribe to continueTest your knowledge
Keep reading Programming for Quantitative Developers
25 lessons in this course, and every other premium course, on one subscription.
- Every lesson in every course, with the worked examples and interactive simulators
- Graded questions on every lesson, with explanations for the wrong answers as well as the right one
- The trainers, timed assessments and brainteaser library that go with them