Balance a tree.