Pregunta de entrevista de Salesforce

Simple algorithms and finding diagnol elements in a binary tree