#include <bits/stdc++.h>
using namespace std;
const string YES = "";
const string NO = "";
int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  int n;
  int h[21];
  int cnt = 1;
  cin >> n;
  for (int i = 1; i <= n; ++i) {
    cin >> h[i];
  }
  for (int i = 2; i <= n; ++i) {
    if (h[1] <= h[i] && h[2] <= h[i]) {
      cnt++;
    }
  }
  cout << cnt << '\n';
  ;
  return 0;
}
