Pregunta de entrevista de Amazon

Some binary tree exercises