#include <bits/stdc++.h>
using namespace std;
const int N = 100000;
int buf[N];
int main() {
  int n, lmax, ans = 1, l;
  cin >> n;
  for (int i = 0; i < n; ++i) {
    cin >> buf[i];
  }
  l = lmax = 0;
  for (int i = 1; i < n; ++i) {
    if (buf[i - 1] >= buf[i]) {
      if (lmax < l) {
        lmax = l;
        ans = i;
      }
      l = 0;
    } else {
      ++l;
    }
  }
  cout << ans << endl;
  return 0;
}
