Tree Balance Metric - Coding problem | OneNoughtOne