#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  long long int a[100000];
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  int result[100001] = {};
  long long int maxnum = -1;
  for (int i = 1; i < n; i++) {
    if (a[i] > maxnum) {
      result[i] = result[i - 1] + 1;
      maxnum = result[i];
    } else
      result[i] = result[i - 1];
  }
  cout << result[n - 1] << endl;
  return 0;
}
