It is raining heavily. But this is the first day for Serval, who just became 3 years old, to go to the kindergarten. Unfortunately, he lives far from kindergarten, and his father is too busy to drive him there. The only choice for this poor little boy is to wait for a bus on this rainy day. Under such circumstances, the poor boy will use the first bus he sees no matter where it goes. If several buses come at the same time, he will choose one randomly.

Serval will go to the bus station at time t, and there are n bus routes which stop at this station. For the i-th bus route, the first bus arrives at time s_i minutes, and each bus of this route comes d_i minutes later than the previous one.

As Serval's best friend, you wonder which bus route will he get on. If several buses arrive at the same time, you can print any of them.

Input

The first line contains two space-separated integers n and t (1≤ n≤ 100, 1≤ t≤ 10^5) — the number of bus routes and the time Serval goes to the station. 

Each of the next n lines contains two space-separated integers s_i and d_i (1≤ s_i,d_i≤ 10^5) — the time when the first bus of this route arrives and the interval between two buses of this route.

Output

Print one number — what bus route Serval will use. If there are several possible answers, you can print any of them.

Examples

Input


2 2
6 4
9 5


Output


1


Input


5 5
3 3
2 5
5 6
4 9
6 1


Output


3


Input


3 7
2 2
2 3
2 4


Output


1

Note

In the first example, the first bus of the first route arrives at time 6, and the first bus of the second route arrives at time 9, so the first route is the answer.

In the second example, a bus of the third route arrives at time 5, so it is the answer.

In the third example, buses of the first route come at times 2, 4, 6, 8, and so fourth, buses of the second route come at times 2, 5, 8, and so fourth and buses of the third route come at times 2, 6, 10, and so on, so 1 and 2 are both acceptable answers while 3 is not.

import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.InputStreamReader;
import java.io.InputStream;

import java.util.ArrayList;
import java.util.Arrays;

import java.util.Comparator;

public class Solution {
//    ----------------------------------------------------------------------------

    public static void main(String[] args) throws IOException {

        //IF INPUT-OUTPUT is via files. uncomment use the below 3 lines of code. comment out the next 4
//        File file = new File("input.txt"); // here input.txt and output.txt being the file names 
//        InputReader in = new InputReader(new FileInputStream(file));
//        PrintWriter out = new PrintWriter(new FileOutputStream("output.txt"));
        //ELSE 
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        Task solver = new Task();
        solver.solve(1, in, out);
        out.close();
    }

    static class Task {

        public void solve(int testNumber, InputReader in, PrintWriter out) throws IOException {
            int n = in.nextInt();
            int t = in.nextInt();

            int ans = Integer.MAX_VALUE;
            int c = 0;

            for (int i = 0; i < n; i++) {
                int s = in.nextInt();
                int d = in.nextInt();

                if (s >= t) {

                    //meet = s;
                    ans = Math.min(s, ans);
                    if (ans == s) {
                        c = i + 1;

                    }
                } else {
                    double N = (double) (t - s) / (double) d;
                    int q = s + ((int) Math.ceil(N) * d);

                    ans = Math.min(q, ans);
                    if (ans == q) {
                        c = i + 1;
                    }

                }

            }

            out.print(c);
        }
    }
//    ----------------------------------------------------------------------------
    // IMPORTANT || COMMON  METHODS
    // PAIR

    static class Pair {

        int x;
        int y;

        // Constructor 
        public Pair(int x, int y) {
            this.x = x;
            this.y = y;
        }

        // how to initialize
//            Pair level[] = new Pair[n];
//            for (int i = 0; i < n; i++) {
//                int x = in.nextInt();
//                int y = in.nextInt();
//
//                level[i] = new Pair(x, y);
//
//            }
        // How to sort
//              PairSort ps = new PairSort();
//              ps.sort(level, 1);
    }

    static class PairSort {

        Pair[] sort(Pair arr[], int i) {
            // Comparator to sort the pair according to second element 
            Arrays.sort(arr, new Comparator<Pair>() {
                @Override
                public int compare(Pair p1, Pair p2) {
                    // 1 sees the first elements ans sorts them in increasing order 
                    // 2 sees the second elements ans sorts them in increasing order 
                    // 3 sees the first elements ans sorts them in decreasing order 
                    // 4 sees the second elements ans sorts them in decreasing order 
                    switch (i) {
                        case 2:
                            return p1.y - p2.y;
                        case 1:
                            return p1.x - p2.x;
                        case 4:
                            return p2.y - p1.y;
                        default:
                            return p2.x - p1.x;
                    }

                }
            });

            return arr;
        }
    }

    // GCD || HCF
    static long GCD(long x, long y) {
        return y == 0 ? x : GCD(y, x % y);
    }

    // LCM 
    static long LCM(long a, long b) {
        return (a * b) / GCD(a, b);
    }

    // Returns the divisors of a number
    static ArrayList Divisors(long n) {
        ArrayList<Long> div = new ArrayList<>();

        for (long i = 1; i <= Math.sqrt(n); i++) {
            if (n % i == 0) {
                div.add(i);

                if (n / i != i) {
                    div.add(n / i);
                }
            }
        }
        return div;
    }

    // PERMUTATIONS
    static void permute(int[] a, int k) {
        if (k == a.length) {

            for (int i = 0; i < k; i++) {

                System.out.print(a[i] + " ");

            }

            System.out.println("");
        } else {
            for (int i = k; i < a.length; i++) {
                int temp = a[k];
                a[k] = a[i];
                a[i] = temp;

                permute(a, k + 1);
                // swapping a[k] and a[i] .
                temp = a[k];
                a[k] = a[i];
                a[i] = temp;
            }
        }

        // How to run 
        //int seq[] = {1, 19, 6}; .. let seq be the array of numbers to be permuted
        //permute(seq, 0); // call this function . 
        //0 -> all permutations ( permutation start from 1st number) 
        //1-> permutations start from 2nd number 
        //2-> permutation start from 3rd number
        // n-1 that array will be returned
    }
//    ----------------------------------------------------------------------------
    // MAIN - INPUT - OUTPUT 

    static class InputReader {

        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public Double nextDouble() {
            return Double.parseDouble(next());
        }

        public long nextLong() {
            return Long.parseLong(next());
        }

        public int[] nextIntArray(int arraySize) {
            int array[] = new int[arraySize];

            for (int i = 0; i < arraySize; i++) {
                array[i] = nextInt();
            }

            return array;
        }

    }
}

// to take the string as a single character each . do this.

/*          BufferedReader inn = new BufferedReader(new InputStreamReader(System.in));
            char[] s1 = inn.readLine().toCharArray();
            // for going through each ch in ch array
            for (char c : s1) {
                if (c != ' ') {

                }

            }
 */
