using System;
using System.Linq;
using System.Collections.Generic;

namespace myapp
{
    class AtCoder_abc104_c
    {
        const int QUESTION_COUNT = 0;
        const int BONUS_SCORE = 1;
        const int QUESTION_TOTAL_SCORE = 2;
        const int IS_SELECTED = 3;

        static int questionPatternCount = 0;
        static int targetScore = 0;
        static int currentBest = 1000;
        static int[][] questionArray;
        public static void Main()
        {

            int[] line1Array = Console.ReadLine().Split(' ').Select(number => int.Parse(number)).ToArray();
            questionPatternCount = line1Array[0];
            targetScore = line1Array[1];

            questionArray = new int[questionPatternCount][];
            for (int i = 0; i < questionPatternCount; i++)
            {
                int[] lineArray = Console.ReadLine().Split(' ').Select(number => int.Parse(number)).ToArray();
                questionArray[i] = new int[4];
                questionArray[i][QUESTION_COUNT] = lineArray[0];
                questionArray[i][BONUS_SCORE] = lineArray[1];
                questionArray[i][QUESTION_TOTAL_SCORE] = (100 * (i + 1) * questionArray[i][QUESTION_COUNT]) + questionArray[i][BONUS_SCORE];
                questionArray[i][IS_SELECTED] = 0;
            }

            RecursiveProcess(0, 1, 0, 0);
            RecursiveProcess(0, 0, 0, 0);

            Console.WriteLine(currentBest);
            return;
        }

        private static void RecursiveProcess(int depth, int isSelected, int totalScore, int totalQuestionCount)
        {
            if (depth > questionPatternCount - 1)
            {
                if (totalScore >= targetScore)
                {
                    if (totalQuestionCount < currentBest)
                    {
                        currentBest = totalQuestionCount;
                    }
                }
                else
                {
                    for (int scoreWeight = questionPatternCount; scoreWeight > 0; scoreWeight--)
                    {
                        if (questionArray[scoreWeight - 1][IS_SELECTED] == 1)
                        {
                            continue;
                        }

                        for (int questionNumber = 0; questionNumber < questionArray[scoreWeight - 1][QUESTION_COUNT]; questionNumber++)
                        {
                            totalScore += 100 * scoreWeight;
                            totalQuestionCount++;

                            if (questionNumber == questionArray[scoreWeight - 1][QUESTION_COUNT] - 1)
                            {
                                totalScore += questionArray[scoreWeight - 1][BONUS_SCORE];
                            }

                            if (totalScore >= targetScore)
                            {
                                if (totalQuestionCount < currentBest)
                                {
                                    currentBest = totalQuestionCount;
                                }
                            }
                        }
                    }
                }

                return;
            }

            if (isSelected == 1)
            {
                totalQuestionCount += questionArray[depth][QUESTION_COUNT];
                totalScore += questionArray[depth][QUESTION_TOTAL_SCORE];
            }

            questionArray[depth][IS_SELECTED] = isSelected;

            RecursiveProcess(depth + 1, 1, totalScore, totalQuestionCount);
            RecursiveProcess(depth + 1, 0, totalScore, totalQuestionCount);
        }
    }
}

Measured memory_bytes: 13396