import Control.Monad
import Data.List
import Data.Maybe

main = do
  [d,g] <- map read . words <$> getLine                    :: IO [Int]
  pcs   <- map (map read . words) <$> replicateM d getLine :: IO [[Int]]
  print $ solve d g 1 0 1 0 pcs

solve _ g _ ui up a [] = a + fromMaybe 1001 (inner ui up g)
  where inner i p r = findIndex (>=r) $ map ((100*i)*) [0..p-1]
solve d g i ui up a ([p,c]:pcs)
  = min (solve d (g-100*i*p-c) (i+1) ui up (a+p) pcs) (solve d g (i+1) i p a pcs)
