0 day streak
Anonymous · shared experience1 Oct 2025 · 2 views

Waymo: Track recent car positions with a bounded history

Interview question #Waymo DSA / coding

Problem. Build a tracker that records each car's position over time and can return the most recent positions.

Follow-up. Keep at most a fixed number of past positions per car.

What was discussed. Which data structures to use, List versus Deque for dropping the oldest entry, edge cases and complexity. A map from car id to a bounded deque gives O(1) inserts and evictions.

0 comments

Comments 0

No comments yet. Ask the author something, or add what happened in your own round.