Pregunta de entrevista de Amazon

Write a program that balances an unbalanced binary tree.