function Main(input) {
  const values = input.split('\n');
  const mountainsSize = values[0];
  const mountainHeights = values[1].split(' ').map(value => Number(value));
  var maxHeight = mountainHeights[0];
  console.log(
    mountainHeights.filter(height => {
      if (maxHeight < height) {
        maxHeight = height;
      }
      return height >= maxHeight;
    }).length
  );
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
