Peak Index in a Mountain Array
Medium
Sorting & Searching (Misc)
A mountain array strictly increases to a peak and then strictly decreases. Print the index of the peak in O(log n).
Constraints
3 <= n <= 10^5
Discussion
No discussions yet.
Shalyam Support
Hi! Ask us anything — we'll reply on WhatsApp or Telegram within 24 hours.