import Control.Monad
import Control.Applicative
import Data.List


-- [a] <- map read . words <$> getLine => [1] -> a == 1
-- 1
-- a <- readLn
-- 1 2 3
-- lst <- map read . words <$> getLine => [1, 2, 3]
-- 1 2 3
-- [l, m, n] <- map read . words <$. getLine :: IO [Int] => [1, 2, 3]
-- 'a'
-- c <- getChar => c == 'a'
--
-- slst <- replicateM h getLine

getBysplit = map read . words <$> getLine

main :: IO()
main = do
  n <- readLn :: IO Int
  lst <- getBysplit :: IO [Int]
  print $ count $ reverse lst

check :: Int -> [Int] -> Bool
check h = all (<=h) 

count :: [Int] -> Int
count [] = 0
count [x] = 1
count (x:xs) = if check x xs
              then 1 + count xs
              else count xs
