import Data.List
 
main = do
  [n, k] <- map read . words <$> getLine
  as <- map read . words <$> getLine
  putStr . show . length . filter (<= (f k as) - k) $ as
 
f k as = minimum . filter (> k) $ [sum xs | xs <- subsequence as]