← All problemsSign in

Algorithm Challenge

Shekhar is your best friend. He loves playing algorithmic games with you wherein one person poses a problem and the other one designs an algorithm for it. Its Shekhar's turn to give you a problem and he claims to have a nice little problem for you. You are given a sorted array (with distinct integers) and you need to find out the location of maximum element in the array. However the problem has

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start