recoverBST, C++