import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Main main = new Main();
        main.solve();
    }
    public void solve() {
        Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int N = scan.nextInt();
        int T = scan.nextInt();
        long answer = Integer.MAX_VALUE;
        for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        }
        if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        }
    }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Main main = new Main();
        main.solve();
    }
    public void solve() {
        Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int N = scan.nextInt();
        int T = scan.nextInt();
        long answer = Integer.MAX_VALUE;
        for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        }
        if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        }
    }
} Main public static void main(String[] args) {
        Main main = new Main();
        main.solve();
    } main {
        Main main = new Main();
        main.solve();
    } Main main = new Main(); main new Main() main.solve() main.solve main String[] args args public void solve() {
        Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int N = scan.nextInt();
        int T = scan.nextInt();
        long answer = Integer.MAX_VALUE;
        for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        }
        if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        }
    } solve {
        Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int N = scan.nextInt();
        int T = scan.nextInt();
        long answer = Integer.MAX_VALUE;
        for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        }
        if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        }
    } Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in))); scan new Scanner(new BufferedReader(new InputStreamReader(System.in))) int N = scan.nextInt(); N scan.nextInt() scan.nextInt scan int T = scan.nextInt(); T scan.nextInt() scan.nextInt scan long answer = Integer.MAX_VALUE; answer Integer.MAX_VALUE Integer Integer.MAX_VALUE for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        } {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        } int c = scan.nextInt(); c scan.nextInt() scan.nextInt scan int t = scan.nextInt(); t scan.nextInt() scan.nextInt scan if (T < t) {
                continue;
            } T < t T t {
                continue;
            } continue; if (c < answer) {
                answer = c;
            } c < answer c answer {
                answer = c;
            } answer = c answer c if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        } answer == Integer.MAX_VALUE answer Integer.MAX_VALUE Integer Integer.MAX_VALUE {
            System.out.println("TLE");
        } System.out.println("TLE") System.out.println System.out System System.out "TLE" {
            System.out.println(answer);
        } System.out.println(answer) System.out.println System.out System System.out answer public class Main {
    public static void main(String[] args) {
        Main main = new Main();
        main.solve();
    }
    public void solve() {
        Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int N = scan.nextInt();
        int T = scan.nextInt();
        long answer = Integer.MAX_VALUE;
        for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        }
        if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        }
    }
} public class Main {
    public static void main(String[] args) {
        Main main = new Main();
        main.solve();
    }
    public void solve() {
        Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int N = scan.nextInt();
        int T = scan.nextInt();
        long answer = Integer.MAX_VALUE;
        for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        }
        if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        }
    }
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Main main = new Main();
        main.solve();
    }
    public void solve() {
        Scanner scan = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int N = scan.nextInt();
        int T = scan.nextInt();
        long answer = Integer.MAX_VALUE;
        for (int i = 0; i < N; i++) {
            int c = scan.nextInt();
            int t = scan.nextInt();
            if (T < t) {
                continue;
            }
            if (c < answer) {
                answer = c;
            }
        }
        if (answer == Integer.MAX_VALUE) {
            System.out.println("TLE");
        } else {
            System.out.println(answer);
        }
    }
}
