import java.util.Scanner;
import java.util.*;
public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int time = sc.nextInt();
        List<Integer> c = new ArrayList<>();
        List<Integer> t = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        }
        int min = 10000000;
        int index = 0;
        for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        }
        if(min >= 10000000){
            System.out.println("TLE");
            return;
        }
        System.out.println(min);
    }
} import java.util.Scanner; Scanner java.util import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int time = sc.nextInt();
        List<Integer> c = new ArrayList<>();
        List<Integer> t = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        }
        int min = 10000000;
        int index = 0;
        for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        }
        if(min >= 10000000){
            System.out.println("TLE");
            return;
        }
        System.out.println(min);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int time = sc.nextInt();
        List<Integer> c = new ArrayList<>();
        List<Integer> t = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        }
        int min = 10000000;
        int index = 0;
        for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        }
        if(min >= 10000000){
            System.out.println("TLE");
            return;
        }
        System.out.println(min);
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int time = sc.nextInt();
        List<Integer> c = new ArrayList<>();
        List<Integer> t = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        }
        int min = 10000000;
        int index = 0;
        for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        }
        if(min >= 10000000){
            System.out.println("TLE");
            return;
        }
        System.out.println(min);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int time = sc.nextInt(); time sc.nextInt() sc.nextInt sc List<Integer> c = new ArrayList<>(); c new ArrayList<>() List<Integer> t = new ArrayList<>(); t new ArrayList<>() for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        } {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        } c.add(sc.nextInt()) c.add c sc.nextInt() sc.nextInt sc t.add(sc.nextInt()) t.add t sc.nextInt() sc.nextInt sc int min = 10000000; min 10000000 int index = 0; index 0 for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        } {
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        } if(t.get(i) > time){
                continue;
            } t.get(i) > time t.get(i) t.get t i time {
                continue;
            } continue; min = Math.min(min,c.get(i)) min Math.min(min,c.get(i)) Math.min Math min c.get(i) c.get c i if(min >= 10000000){
            System.out.println("TLE");
            return;
        } min >= 10000000 min 10000000 {
            System.out.println("TLE");
            return;
        } System.out.println("TLE") System.out.println System.out System System.out "TLE" return; System.out.println(min) System.out.println System.out System System.out min String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int time = sc.nextInt();
        List<Integer> c = new ArrayList<>();
        List<Integer> t = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        }
        int min = 10000000;
        int index = 0;
        for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        }
        if(min >= 10000000){
            System.out.println("TLE");
            return;
        }
        System.out.println(min);
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int time = sc.nextInt();
        List<Integer> c = new ArrayList<>();
        List<Integer> t = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        }
        int min = 10000000;
        int index = 0;
        for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        }
        if(min >= 10000000){
            System.out.println("TLE");
            return;
        }
        System.out.println(min);
    }
} Main
import java.util.Scanner;
import java.util.*;
public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int time = sc.nextInt();
        List<Integer> c = new ArrayList<>();
        List<Integer> t = new ArrayList<>();
        for (int i = 0; i < n; i++) {
            c.add(sc.nextInt());
            t.add(sc.nextInt());
        }
        int min = 10000000;
        int index = 0;
        for(int i = 0;i < n;i++){
            if(t.get(i) > time){
                continue;
            }
            min = Math.min(min,c.get(i));
        }
        if(min >= 10000000){
            System.out.println("TLE");
            return;
        }
        System.out.println(min);
    }
}
