#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ll t;
  t = 1;
  while (t--) {
    ll n, d;
    cin >> n >> d;
    vector<pair<ll, ll>> p(n);
    for (ll i = 0; i < n; i++) {
      cin >> p[i].first >> p[i].second;
    }
    ll mi = 1e8;
    ll ans = 0;
    ll ansp = 0;
    ll jin = 1e8;
    for (ll i = 0; i < n; i++) {
      ll rem = d - p[i].first;
      if (rem >= 0) {
        ll kem = ceil(ceil(rem) / (p[i].second));
        ll jem = kem * p[i].second + p[i].first;
        if (jem < mi) {
          mi = jem;
          ans = i + 1;
        }
      }
    }
    for (ll i = 0; i < n; i++) {
      ll rem = d - p[i].first;
      if (rem < 0) {
        if (p[i].first < mi) {
          mi = p[i].first;
          ans = i + 1;
        }
      }
    }
    cout << ans << "\n";
  }
}
