Amazon | Onsite | Binary Tree Top Down View
Anonymous User
13078

Given the root of a binary tree, return a list of values of the nodes that would be seen from the "top down" perspective of the tree, as seen from "left to right". Very similar to the right side view question.

Input: TreeNode
Output: List of integers

Example:

		1
	2      3
4      5      6 

Would return {4, 2, 1, 3, 6}

Genuinly not sure how to solve this.

Comments (35)