A hiking trail is described by n elevation readings taken in order. The elevations strictly increase up to a single summit and then strictly decrease afterward (either the rising part or the falling part may be empty). Because the profile is strictly increasing then strictly decreasing, there is exactly one summit: the position holding the unique maximum elevation.
Print the 0-indexed position of that summit.
Input format
Line 1: an integer n, the number of readings.
Line 2: n space-separated integers, the elevations in trail order.
Output format
A single integer: the 0-indexed position of the summit.
Constraints
- 1 <= n <= 100000
- -1000000000 <= each elevation <= 1000000000
- The elevations strictly increase to the summit, then strictly decrease.