#include <bits/stdc++.h>
using namespace std;
const int oo = 2139063143;
const int N = 1010000;
const int P = 1000000007;
const double eps = 1e-7;
template <typename T>
inline void sc(T &x) {
  x = 0;
  static int p;
  p = 1;
  static char c;
  c = getchar();
  while (!isdigit(c)) {
    if (c == '-') p = -1;
    c = getchar();
  }
  while (isdigit(c)) {
    x = (x << 1) + (x << 3) + (c - 48);
    c = getchar();
  }
  x *= p;
}
template <typename T>
inline void print(T x) {
  if (x < 0) putchar('-'), x = -x;
  if (x >= 10) print(x / 10);
  putchar(x % 10 + '0');
}
template <typename T>
inline void pr(T x) {
  print(x), putchar('\n');
}
template <typename T1, typename T2>
void chkmax(T1 &A, T2 B) {
  A = A >= B ? A : B;
}
template <typename T1, typename T2>
void chkmin(T1 &A, T2 B) {
  A = A <= B ? A : B;
}
int n;
long long m;
struct LY {
  long long v, c;
} a[N];
struct YL {
  long long f, g;
} b[N];
bool operator<(YL A, YL B) { return A.f != B.f ? A.f < B.f : A.g >= B.g; }
long long up(long long x, long long y) { return x / y + (x % y > 0); }
YL calc(int x, int y) {
  long long h = up(a[y].c - b[x].g, a[x].v);
  return (YL){h + b[x].f, h * a[x].v + b[x].g - a[y].c};
}
struct ST {
  int l, id;
} q[N];
int he = 1, ta = 0;
int get(int x, int y) {
  if (!x) return 1;
  int L = y, R = n + 1;
  while (L + 1 < R) {
    int mid = (L + R) >> 1;
    if (calc(y, mid) < calc(x, mid))
      R = mid;
    else
      L = mid;
  }
  return R;
}
void update(int id) {
  while (he <= ta && calc(id, q[ta].l) < calc(q[ta].id, q[ta].l)) --ta;
  int g = get(q[ta].id, id);
  if (g <= n) q[++ta] = (ST){g, id};
}
YL getpos(int id) {
  q[ta + 1].l = n + 1;
  while (he <= ta && q[he + 1].l <= id) ++he;
  return calc(q[he].id, id);
}
int main() {
  sc(n), sc(m);
  for (int i = 1; i <= n; i++) sc(a[i].v), sc(a[i].c);
  sort(a + 1, a + n + 1,
       [](LY A, LY B) { return A.v != B.v ? A.v < B.v : A.c < B.c; });
  int k = 1;
  for (int i = 2; i <= n; i++)
    if (a[i].v == a[k].v || a[i].v > m)
      continue;
    else {
      while (k && a[i].c <= a[k].c) --k;
      a[++k] = a[i];
    }
  n = k;
  a[++n] = (LY){0, m};
  b[1] = (YL){0, 0}, update(1);
  for (int i = 2; i <= n; i++) {
    b[i] = getpos(i);
    if (i < n) update(i);
  }
  pr(b[n].f);
  return 0;
}
