main :: IO ()
main = do
    n <- readLn :: IO Int
    ns <- inputs :: IO [Int]
    print (f n ns)

inputs :: Read a => IO [a]
inputs = map read . words <$> getLine

f :: Int -> [Int] -> Int
f x xs = length [ () | n <- [1..x], maximum (take n xs) == xs !! (n - 1) ]
