Locate any index where the element is strictly greater than its neighbors.
Constraints
Example
find_peak_element([1,2,3,1]) -> 2 find_peak_element([1,2,1,3,5,6,4]) -> 5 # 1 is also acceptable
Recent Submissions
No submissions yet — hit Run Tests to try!
Hints