Vertical Order Traversal of a Binary Tree at DoorDash
Hard53.2% acceptance
This problem has 50.0% frequency at DoorDash.
Problem Description
Given the `root` of a binary tree, calculate the **vertical order traversal** of the binary tree. For each node at position `(row, col)`, its left and right children will be at positions `(row + 1, col - 1)` and `(row + 1, col + 1)` respectively. The root of the tree is at `(0, 0)`. The **vertical...
Read full problem and hintsTopics
Also asked at 10 companies
More DoorDash Questions
Binary Tree Maximum Path SumHardLongest Increasing Path in a MatrixHardSearch Suggestions SystemMediumMaximum Profit in Job SchedulingHardMost Profit Assigning WorkMedium
View all DoorDash questions