#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, k, a, c = 0, d = 0, e = 0, sum = 0, num = 0;
  cin >> n >> k;
  int b[123456] = {0};
  for (int h = 0; h < n; h++) {
    cin >> a >> b[h];
    sum = max(sum, a);
    num += b[h];
    e += a;
  }
  sort(b, b + n);
  if (num >= k) {
    for (int h = n - 1; h >= 0; h--) {
      d += b[h];
      if (d >= k && n - h <= k / sum) {
        cout << n - h << endl;
        cin >> n;
        return 0;
      }
    }
  }
  for (int h = 0; h < n; h++) {
    if (b[h] < sum) {
      num = num - b[h];
      c++;
    }
  }
  if ((k - num) % sum == 0) {
    cout << (k - num) / sum + n - c << endl;
  } else {
    cout << (k - num) / sum + n - c + 1 << endl;
  }
  cin >> n;
}
