import std.stdio, std.string, std.range, std.conv, std.array, std.algorithm, std.math, std.typecons;

void main() {
    const N = readln.chomp.to!int;
    const hs = readln.split.to!(int[]);
    N.iota.filter!(i => reduce!max(0, hs[0..i]) <= hs[i]).walkLength.writeln;
}

