Yext Interview Question

Debug this program (re-ordering binary tree)