#include <bits/stdc++.h>
using namespace std;
//*******************
// Mahmoud Magdy    *
//*******************
#define ll long long
#define endl "\n"

void fast()
{
    ios_base :: sync_with_stdio( 0 ) ;
    cin.tie( 0 ) ;
    cout.tie( 0 ) ;
}
inline int D()
{
    int m ;
    cin>>m;
    return m ;
}
inline ll lD()
{
    ll m ;
    cin>>m;
    return m ;
}
inline double dD()
{
    double m ;
    cin>>m;
    return m ;
}
int a[100005],b[100005];
int main()
{
 int n=D(),k=D();
   for(int i=0;i<n;++i){
    a[i]=D();
    b[i]=D();
   }
   sort(a,a+n);
   int mx=a[n-1];
   ll sum=0;
   int c=0;
   for(int i=0;i<n;++i){
    if(mx<=b[i]){
        sum+=b[i];
        c++;
        }
   }
   bool f=false ;
   if(sum>=k)
    cout<<c<<endl;
    else if(mx==1){
        cout<<c+(k-sum)<<endl;
    }
    else {
        for(int i=1;i<100001;++i)
        {
            if((sum+(mx*i)>=k){
                cout<<c+i<<endl;
                return 0;
            }
        }
    }
  cout<<((k-sum)/mx)-c<<endl;;
}

