def main():

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

    pc = []

    min_ct = 0

    for i in range(D):

        p, c = list(map(int, input().split()))

        pc.append([p, c])

        min_ct += p



    bonus = [set()]

    for i in range(D):

        temp = []

        for st in bonus:

            temp.append(st | {i})

        bonus += temp

    # print(bonus)



    for comp in bonus:

        pt = sum([pc[i][0]*100*(i+1)+pc[i][1] for i in comp])

        ct = sum([pc[i][0] for i in comp])

        j = 0

        # print(comp, pt, j)

        for i in range(D-1, -1, -1):

            if i not in comp:

                while j < pc[i][0] and pt < G:

                    pt += 100 * (i+1)

                    j += 1

                break

        # print(comp, pt, j)

        if pt >= G:

            min_ct = min(min_ct, ct+j)



    return min_ct



if __name__ == '__main__':

    print((main()))

def main():



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

    A = []

    for i in range(D):

        p, c = list(map(int, input().split()))

        A.append([i, p, c])

    A = A[::-1]



    cur = [[0, 0]]

    used = [set()]



    for i, p, c in A:

        temp = []

        temp_used = []

        for j in range(len(cur)):

            temp.append(cur[j])

            temp_used.append(used[j])

            temp.append([cur[j][0]+ 100*(i+1)*p+c, cur[j][1] + p])

            temp_used.append(used[j] | {i})

        cur = temp

        used = temp_used

    # 

    # print(cur)

    # print(used)



    ans = float('inf')

    for j in range(len(cur)):

        if cur[j][0] >= G:

            ans = min(ans, cur[j][1])

        else:

            for i, p, c in A:

                if i not in used[j]:

                    if cur[j][0] + 100 * (i+1) * (p-1) < G:

                        cur[j][0] += 100 * (i+1) * (p-1)

                        cur[j][1] += p-1

                    else:

                        if (G - cur[j][0]) % (100*(i+1)) == 0:

                            ans = min(ans, cur[j][1] + (G - cur[j][0]) // (100*(i+1)))

                        else:

                            ans = min(ans, cur[j][1] + (G - cur[j][0]) // (100*(i+1)) + 1)

                        break

    return ans







if __name__ == '__main__':

    print((main()))
def main():
    D, G = list(map(int, input().split()))
    pc = []
    min_ct = 0
    for i in range(D):
        p, c = list(map(int, input().split()))
        pc.append([p, c])
        min_ct += p
    bonus = [set()]
    for i in range(D):
        temp = []
        for st in bonus:
            temp.append(st | {i})
        bonus += temp
    # print(bonus)
    for comp in bonus:
        pt = sum([pc[i][0] * 100 * (i + 1) + pc[i][1] for i in comp])
        ct = sum([pc[i][0] for i in comp])
        j = 0
        # print(comp, pt, j)
        for i in range(D - 1, -1, -1):
            if i not in comp:
                while j < pc[i][0] and pt < G:
                    pt += 100 * (i + 1)
                    j += 1
                break
        # print(comp, pt, j)
        if pt >= G:
            min_ct = min(min_ct, ct + j)
    return min_ct


if __name__ == "__main__":
    print((main()))

def main():
    D, G = list(map(int, input().split()))
    A = []
    for i in range(D):
        p, c = list(map(int, input().split()))
        A.append([i, p, c])
    A = A[::-1]
    cur = [[0, 0]]
    used = [set()]
    for i, p, c in A:
        temp = []
        temp_used = []
        for j in range(len(cur)):
            temp.append(cur[j])
            temp_used.append(used[j])
            temp.append([cur[j][0] + 100 * (i + 1) * p + c, cur[j][1] + p])
            temp_used.append(used[j] | {i})
        cur = temp
        used = temp_used
    #
    # print(cur)
    # print(used)
    ans = float("inf")
    for j in range(len(cur)):
        if cur[j][0] >= G:
            ans = min(ans, cur[j][1])
        else:
            for i, p, c in A:
                if i not in used[j]:
                    if cur[j][0] + 100 * (i + 1) * (p - 1) < G:
                        cur[j][0] += 100 * (i + 1) * (p - 1)
                        cur[j][1] += p - 1
                    else:
                        if (G - cur[j][0]) % (100 * (i + 1)) == 0:
                            ans = min(
                                ans, cur[j][1] + (G - cur[j][0]) // (100 * (i + 1))
                            )
                        else:
                            ans = min(
                                ans, cur[j][1] + (G - cur[j][0]) // (100 * (i + 1)) + 1
                            )
                        break
    return ans


if __name__ == "__main__":
    print((main()))

-    pc = [] -    min_ct = 0 +    A = [] -        pc.append([p, c]) -        min_ct += p -    bonus = [set()] -    for i in range(D): +        A.append([i, p, c]) +    A = A[::-1] +    cur = [[0, 0]] +    used = [set()] +    for i, p, c in A: -        for st in bonus: -            temp.append(st | {i}) -        bonus += temp -    # print(bonus) -    for comp in bonus: -        pt = sum([pc[i][0] * 100 * (i + 1) + pc[i][1] for i in comp]) -        ct = sum([pc[i][0] for i in comp]) -        j = 0 -        # print(comp, pt, j) -        for i in range(D - 1, -1, -1): -            if i not in comp: -                while j < pc[i][0] and pt < G: -                    pt += 100 * (i + 1) -                    j += 1 -                break -        # print(comp, pt, j) -        if pt >= G: -            min_ct = min(min_ct, ct + j) -    return min_ct +        temp_used = [] +        for j in range(len(cur)): +            temp.append(cur[j]) +            temp_used.append(used[j]) +            temp.append([cur[j][0] + 100 * (i + 1) * p + c, cur[j][1] + p]) +            temp_used.append(used[j] | {i}) +        cur = temp +        used = temp_used +    # +    # print(cur) +    # print(used) +    ans = float("inf") +    for j in range(len(cur)): +        if cur[j][0] >= G: +            ans = min(ans, cur[j][1]) +        else: +            for i, p, c in A: +                if i not in used[j]: +                    if cur[j][0] + 100 * (i + 1) * (p - 1) < G: +                        cur[j][0] += 100 * (i + 1) * (p - 1) +                        cur[j][1] += p - 1 +                    else: +                        if (G - cur[j][0]) % (100 * (i + 1)) == 0: +                            ans = min( +                                ans, cur[j][1] + (G - cur[j][0]) // (100 * (i + 1)) +                            ) +                        else: +                            ans = min( +                                ans, cur[j][1] + (G - cur[j][0]) // (100 * (i + 1)) + 1 +                            ) +                        break +    return ans