import java.util.Scanner;

class Main{
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int N=sc.nextInt();
		int T=sc.nextInt();
		int[][] are=new int[N][2];
		for(int i=0; i<N; i++) {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		}
		int cost=1145141919;
		for(int i=0; i<N; i++) {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		}
		if(cost==1145141919) {
			System.out.println("TLE");
		}
		else {
			System.out.println(cost);
		}
	}
} import java.util.Scanner; Scanner java.util class Main{
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int N=sc.nextInt();
		int T=sc.nextInt();
		int[][] are=new int[N][2];
		for(int i=0; i<N; i++) {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		}
		int cost=1145141919;
		for(int i=0; i<N; i++) {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		}
		if(cost==1145141919) {
			System.out.println("TLE");
		}
		else {
			System.out.println(cost);
		}
	}
} Main public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int N=sc.nextInt();
		int T=sc.nextInt();
		int[][] are=new int[N][2];
		for(int i=0; i<N; i++) {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		}
		int cost=1145141919;
		for(int i=0; i<N; i++) {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		}
		if(cost==1145141919) {
			System.out.println("TLE");
		}
		else {
			System.out.println(cost);
		}
	} main {
		Scanner sc=new Scanner(System.in);
		int N=sc.nextInt();
		int T=sc.nextInt();
		int[][] are=new int[N][2];
		for(int i=0; i<N; i++) {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		}
		int cost=1145141919;
		for(int i=0; i<N; i++) {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		}
		if(cost==1145141919) {
			System.out.println("TLE");
		}
		else {
			System.out.println(cost);
		}
	} Scanner sc=new Scanner(System.in); sc new Scanner(System.in) int N=sc.nextInt(); N sc.nextInt() sc.nextInt sc int T=sc.nextInt(); T sc.nextInt() sc.nextInt sc int[][] are=new int[N][2]; are new int[N][2] N 2 for(int i=0; i<N; i++) {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		} {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		} are[i][0]=sc.nextInt() are[i][0] are[i] are i 0 sc.nextInt() sc.nextInt sc are[i][1]=sc.nextInt() are[i][1] are[i] are i 1 sc.nextInt() sc.nextInt sc int cost=1145141919; cost 1145141919 for(int i=0; i<N; i++) {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		} {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		} if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			} T>=are[i][1] T are[i][1] are[i] are i 1 {
				cost=Math.min(cost, are[i][0]);
			} cost=Math.min(cost, are[i][0]) cost Math.min(cost, are[i][0]) Math.min Math cost are[i][0] are[i] are i 0 if(cost==1145141919) {
			System.out.println("TLE");
		}
		else {
			System.out.println(cost);
		} cost==1145141919 cost 1145141919 {
			System.out.println("TLE");
		} System.out.println("TLE") System.out.println System.out System System.out "TLE" {
			System.out.println(cost);
		} System.out.println(cost) System.out.println System.out System System.out cost String[] args args
import java.util.Scanner;

class Main{
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int N=sc.nextInt();
		int T=sc.nextInt();
		int[][] are=new int[N][2];
		for(int i=0; i<N; i++) {
			are[i][0]=sc.nextInt();
			are[i][1]=sc.nextInt();
		}
		int cost=1145141919;
		for(int i=0; i<N; i++) {
			if(T>=are[i][1]) {
				cost=Math.min(cost, are[i][0]);
			}
		}
		if(cost==1145141919) {
			System.out.println("TLE");
		}
		else {
			System.out.println(cost);
		}
	}
}