Quant Interview Practice Questions
题目详情
You are building an order book for a high-frequency trading system. The order book needs to efficiently support the following operations:
- Insertion: Adding new orders at specific price levels.
- Best Bid/Ask Retrieval: Quickly finding the highest bid price and the lowest ask price. Price levels are represented as keys. You are considering using either a HashMap or a balanced Binary Search Tree (BST), such as a TreeMap, to store the price levels and their corresponding orders. Why is a bala