solver :: [Int] -> Int -> Int
solver ls x = length $ takeWhile (x >=) (scanl (+) 0 ls)

main :: IO ()
main = do
  (n:x:_) <- map read . words <$> getLine
  dat <- map read . words <$> getLine
  print $ solver dat x
