Pergunta de entrevista da empresa Amazon

Tree-structure and optimization-based algorithm questions.