#include <bits/stdc++.h>
using namespace std;
const long long INF = 1LL << 60;
const long long MOD = 1e9 + 7;
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long lcm(long long a, long long b) { return a / gcd(a, b) * b; }
void Yes() { cout << "Yes" << endl; }
void No() { cout << "No" << endl; }
void YN(bool b) { cout << (b ? "Yes" : "No") << endl; }
signed main() {
  long long n, m;
  cin >> n >> m;
  vector<pair<long long, char>> a(n * 2);
  for (long long i = 0; i < (n); ++i) {
    cin >> a[i].first >> a[i + n].first;
    a[i].second = 'a';
    a[i + n].second = 'b';
  }
  sort(a.begin(), a.end());
  reverse(a.begin(), a.end());
  long long ans = 0, sum = 0, idx = 0;
  while (sum <= m) {
    ans++;
    sum += a[idx].first;
    if (a[idx].second == 'b')
      idx++;
    else {
      ans += (m - sum) / a[idx].first;
      if ((m - sum) % a[idx].first != 0) ans++;
      break;
    }
  }
  cout << (ans) << endl;
  return 0;
}
