// Find Peak Element — MEDIUM
// Category: binary-search
A peak element is an element that is strictly greater than its neighbors.
Given an integer array `nums`, find a peak element and return its index. If the array contains multiple peaks, return the index of any of them.
You may imagine that `nums[-1] = nums[n] = -∞`.
Example: nums = [1,2,3,1]
Output: 2