Solve BalancedBinaryTree.