SAP Ariba interview question

program to find if the binary tree us height balanced