Domanda di colloquio di Tata Communications

problem on dynamic programming, tree