Pregunta de entrevista de Meta

About matrix manipulation and tree problems.