Pergunta de entrevista da empresa RBC

Design a program to build and update a market depth book.

Resposta da entrevista

Sigiloso

12 de jul. de 2012

The relevant points are a quick look up for the security, putting the new quote in the proper sorted order on the proper side (bid / ask), checking for consistency of the book (crossed books - bids being higher than asks), how to handle crossed books etc. The key was the appropriate data structures for these aspects.