D,G = list(map(int,input().split()))

pc = [list(map(int,input().split())) for i in range(D)]



#print(pc)

ans = float("inf")



for i in range(2**D):

    sum = 0

    count = 0

    rem = set(range(1,D+1))

    for j in range(D):

        if (i >> j) & 1:

            sum += pc[j][0]*100*(j+1)+pc[j][1]

            count += pc[j][0]

            rem.discard(j+1)

    if sum < G:

        k = max(rem)-1

        n = min(pc[k][0],-(-(G-sum)//((k+1)*100)))

        count += n

        sum += n*100*(k+1)

    if sum >= G:

        ans = min(ans,count)



print(ans)

def dfs (i,sum,count,rem):

    global ans

    if i == D:

        if sum < G:

            k = max(rem)

            n = min(pc[k-1][0],-(-(G-sum)//(k*100)))

            count += n

            sum += n*100*k

        if sum >= G:

            ans = min(ans,count)

    else:

        dfs(i+1,sum,count,rem)

        dfs(i+1,sum+pc[i][0]*100*(i+1)+pc[i][1],count+pc[i][0],rem-{i+1})



D,G = list(map(int,input().split()))

pc = [list(map(int,input().split())) for i in range(D)]



ans = float("inf")



dfs(0,0,0,set(range(1,D+1)))

print(ans)

D, G = list(map(int, input().split()))
pc = [list(map(int, input().split())) for i in range(D)]
# print(pc)
ans = float("inf")
for i in range(2**D):
    sum = 0
    count = 0
    rem = set(range(1, D + 1))
    for j in range(D):
        if (i >> j) & 1:
            sum += pc[j][0] * 100 * (j + 1) + pc[j][1]
            count += pc[j][0]
            rem.discard(j + 1)
    if sum < G:
        k = max(rem) - 1
        n = min(pc[k][0], -(-(G - sum) // ((k + 1) * 100)))
        count += n
        sum += n * 100 * (k + 1)
    if sum >= G:
        ans = min(ans, count)
print(ans)

def dfs(i, sum, count, rem):
    global ans
    if i == D:
        if sum < G:
            k = max(rem)
            n = min(pc[k - 1][0], -(-(G - sum) // (k * 100)))
            count += n
            sum += n * 100 * k
        if sum >= G:
            ans = min(ans, count)
    else:
        dfs(i + 1, sum, count, rem)
        dfs(
            i + 1,
            sum + pc[i][0] * 100 * (i + 1) + pc[i][1],
            count + pc[i][0],
            rem - {i + 1},
        )


D, G = list(map(int, input().split()))
pc = [list(map(int, input().split())) for i in range(D)]
ans = float("inf")
dfs(0, 0, 0, set(range(1, D + 1)))
print(ans)

+def dfs(i, sum, count, rem): +    global ans +    if i == D: +        if sum < G: +            k = max(rem) +            n = min(pc[k - 1][0], -(-(G - sum) // (k * 100))) +            count += n +            sum += n * 100 * k +        if sum >= G: +            ans = min(ans, count) +    else: +        dfs(i + 1, sum, count, rem) +        dfs( +            i + 1, +            sum + pc[i][0] * 100 * (i + 1) + pc[i][1], +            count + pc[i][0], +            rem - {i + 1}, +        ) + + -# print(pc) -for i in range(2**D): -    sum = 0 -    count = 0 -    rem = set(range(1, D + 1)) -    for j in range(D): -        if (i >> j) & 1: -            sum += pc[j][0] * 100 * (j + 1) + pc[j][1] -            count += pc[j][0] -            rem.discard(j + 1) -    if sum < G: -        k = max(rem) - 1 -        n = min(pc[k][0], -(-(G - sum) // ((k + 1) * 100))) -        count += n -        sum += n * 100 * (k + 1) -    if sum >= G: -        ans = min(ans, count) +dfs(0, 0, 0, set(range(1, D + 1)))