main = do
    [d,g] <- map read . words <$> getLine
    contents <- lines <$> getContents

    let pcs = map (map read . words) contents
    let feasible_set = feasible (reverse pcs) []

    print $ minimum (map sum [solved | solved <- feasible_set, (score pcs (zip [1..d] solved)) >= g])


feasible [] acc = acc
feasible ([p,c]:pcs) [] = feasible pcs [[x] | x <- [0..p]]
feasible ([p,c]:pcs) acc = feasible pcs [x:xs | x <- [0..p], xs <- acc]


points :: [Int] -> (Int,Int) -> Int
points [p,c] (i,x) = 100 * i * x + if x == p then c else 0

score :: [[Int]] -> [(Int,Int)] -> Int
score pcs solved_zip = sum (zipWith (points) pcs solved_zip)