N = gets.to_i a = (1..N).map {gets.to_i} ans = a[1..-1].inject([1]) {|memo, x| memo.push( if x > a[0] memo[-1] + 1 else memo[-1] end ) } puts ans