Solve BinaryTreeExterior.