import java.util.*;
public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int all = sc.nextInt();        //fre 次數
		int T = sc.nextInt();
		int route[] = new int[all];
		int time[] = new int[all];
		int min = 9999;
		for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		}
		for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		}
		if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		}
	}
} import java.util.*; util.* java public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int all = sc.nextInt();        //fre 次數
		int T = sc.nextInt();
		int route[] = new int[all];
		int time[] = new int[all];
		int min = 9999;
		for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		}
		for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		}
		if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		}
	}
} Main public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int all = sc.nextInt();        //fre 次數
		int T = sc.nextInt();
		int route[] = new int[all];
		int time[] = new int[all];
		int min = 9999;
		for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		}
		for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		}
		if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		}
	} main {
		Scanner sc = new Scanner(System.in);
		int all = sc.nextInt();        //fre 次數
		int T = sc.nextInt();
		int route[] = new int[all];
		int time[] = new int[all];
		int min = 9999;
		for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		}
		for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		}
		if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int all = sc.nextInt(); all sc.nextInt() sc.nextInt sc int T = sc.nextInt(); T sc.nextInt() sc.nextInt sc int route[] = new int[all]; route new int[all] all int time[] = new int[all]; time new int[all] all int min = 9999; min 9999 for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		} int i = 0 ; int i = 0 ; i 0 i<all i all i++ i++ i {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		} {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		} route[i]=sc.nextInt() route[i] route i sc.nextInt() sc.nextInt sc time[i]=sc.nextInt() time[i] time i sc.nextInt() sc.nextInt sc for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		} int i = 0 ; int i = 0 ; i 0 i<all i all i++ i++ i {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		} {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		} if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			} time[i]<=T time[i] time i T {
				if(route[i]<min) {
					min = route[i];
				}
			} if(route[i]<min) {
					min = route[i];
				} route[i]<min route[i] route i min {
					min = route[i];
				} min = route[i] min route[i] route i if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		} min!=9999 min 9999 {
			System.out.println(min);
		} System.out.println(min) System.out.println System.out System System.out min {
			System.out.println("TLE");
		} System.out.println("TLE") System.out.println System.out System System.out "TLE" String args[] args public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int all = sc.nextInt();        //fre 次數
		int T = sc.nextInt();
		int route[] = new int[all];
		int time[] = new int[all];
		int min = 9999;
		for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		}
		for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		}
		if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		}
	}
} public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int all = sc.nextInt();        //fre 次數
		int T = sc.nextInt();
		int route[] = new int[all];
		int time[] = new int[all];
		int min = 9999;
		for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		}
		for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		}
		if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		}
	}
} Main
import java.util.*;
public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int all = sc.nextInt();        //fre 次數
		int T = sc.nextInt();
		int route[] = new int[all];
		int time[] = new int[all];
		int min = 9999;
		for(int i = 0 ; i<all; i++) {
			route[i]=sc.nextInt();
			time[i]=sc.nextInt();
		}
		for(int i = 0 ; i<all;i++) {
			if(time[i]<=T) {
				if(route[i]<min) {
					min = route[i];
				}
			}
		}
		if(min!=9999) {
			System.out.println(min);
		}
		else {
			System.out.println("TLE");
		}
	}
}
