Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

README.md

Get all Values at a Certain Height in a Binary Tree

This problem was asked by Amazon.

Description

Given a binary tree, return all values given a certain height h.

Example

    1
   / \
  2   3
 / \   \
4   5   7

h = 3

Output: [4, 5, 7]