program allgreen
implicit none
integer :: D, G, I, J, K
integer :: co, su
integer, allocatable, dimension(:) :: P, PP, C, counter, sum

read(*,*) D, G

allocate(P(D))
allocate(PP(D))
allocate(C(D))
allocate(counter(2**D))
allocate(sum(2**D))

do I = 1, D
read(*,*) P(I), C(I)
end do

do I = 1, 2**D
counter(I) = 10000
sum(I) = 10000
end do
do I = 1, 2**D
su = 0
co = 0
 do J = 1, D
 PP(J) = P(J)
 end do
 do J = 1, D
  if (btest(I-1,J-1)) then
  su = su + PP(J)*100*J + C(J)
  co = co + PP(J)
  PP(J) = 0
  end if
 end do
! write(*,*) su, co
 if (su>=G) then
 sum(I) = su
 counter(I) = co
 cycle
 end if
 do J = D, 1, -1
  if (PP(J)/=0) then
   do K = 1, (PP(J)-1)
   su = su + 100*J
   co = co + 1
!   write(*,*) su, co
    if (su>=G) then
    sum(I) = su
    counter(I) = co
    exit
    end if
   end do
  end if
 if (su>=G) exit
 end do
end do

write(*,*) minval(counter)

end program