Binary Tree Level Order Traversal
Medium · Queue & Deque · about 15 minutes
Asked at Amazon, Meta, Microsoft, LinkedIn, Confluent, Grammarly.
Read a binary tree one depth at a time, starting at the root. Return a list with one entry per depth, top to bottom, where each entry lists that depth's values from left to right.