These are Data Structures questions of the kind Microsoft actually asks — the patterns reported from Microsoft's AI-engineering rounds, where design trade-offs, scale and failure modes matter as much as definitions. Treat this page as a mock interview: say every answer out loud before revealing it. If one surprises you, the lesson behind it is linked at the bottom.
Microsoft Data Structures concept questions
Find the lowest common ancestor (LCA) of two values in a binary search tree. Why is the BST version so much easier than in a plain binary tree?
Asked in
Find the median of a stream of numbers: numbers keep arriving, and after each you may be asked the current median. Design the structure.
Asked in
Microsoft Data Structures applied & hands-on questions
The diameter is the longest path (in edges) between any two nodes, not necessarily through the root. Compute it in one traversal.
Asked in
How to use this page: Microsoft rarely asks something you've never seen — they ask a standard Data Structures concept and then push one level deeper ("why?", "what would you do if..."). Master the concept in the Data Structures course lessons, and the follow-up stops being scary.
Keep practising: Hash Tables, Linked Lists, Heaps and Choosing the Right Structure cover what most Microsoft Data Structures rounds test.

