Morgan Stanley Interview Question

peak element in the array. inorder traversal inorder successor