Nokia Interview Question

A coding question to check if tree is balanced or not