import java.util.*;

public class Main {
    
	public static Scanner sc = new Scanner(System.in);
	
	public static void main(String[] args) {
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int min = Integer.MAX_VALUE;
		int count = -1;
		
		for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		
		for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    }
	
		if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);}
    }
} import java.util.*; util.* java public class Main {
    
	public static Scanner sc = new Scanner(System.in);
	
	public static void main(String[] args) {
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int min = Integer.MAX_VALUE;
		int count = -1;
		
		for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		
		for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    }
	
		if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);}
    }
} Main public static Scanner sc = new Scanner(System.in); sc new Scanner(System.in) public static void main(String[] args) {
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int min = Integer.MAX_VALUE;
		int count = -1;
		
		for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		
		for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    }
	
		if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);}
    } main {
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int min = Integer.MAX_VALUE;
		int count = -1;
		
		for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		
		for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    }
	
		if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);}
    } int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int T = sc.nextInt(); T sc.nextInt() sc.nextInt sc int[] c = new int[N]; c new int[N] N int[] t = new int[N]; t new int[N] N int min = Integer.MAX_VALUE; min Integer.MAX_VALUE Integer Integer.MAX_VALUE int count = -1; count -1 1 for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		} {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		} c[i] = sc.nextInt() c[i] c i sc.nextInt() sc.nextInt sc t[i] = sc.nextInt() t[i] t i sc.nextInt() sc.nextInt sc for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    } {
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    } if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			} min > c[i] && T >= t[i] min > c[i] min c[i] c i T >= t[i] T t[i] t i {
		    min = Math.min(min,c[i]);
		    count = i;
			} min = Math.min(min,c[i]) min Math.min(min,c[i]) Math.min Math min c[i] c i count = i count i if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);} count == -1 count -1 1 { System.out.println("TLE");} System.out.println("TLE") System.out.println System.out System System.out "TLE" {System.out.println(c[count]);} System.out.println(c[count]) System.out.println System.out System System.out c[count] c count String[] args args public class Main {
    
	public static Scanner sc = new Scanner(System.in);
	
	public static void main(String[] args) {
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int min = Integer.MAX_VALUE;
		int count = -1;
		
		for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		
		for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    }
	
		if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);}
    }
} public class Main {
    
	public static Scanner sc = new Scanner(System.in);
	
	public static void main(String[] args) {
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int min = Integer.MAX_VALUE;
		int count = -1;
		
		for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		
		for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    }
	
		if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);}
    }
} Main
import java.util.*;

public class Main {
    
	public static Scanner sc = new Scanner(System.in);
	
	public static void main(String[] args) {
		int N = sc.nextInt();
		int T = sc.nextInt();
		int[] c = new int[N];
		int[] t = new int[N];
		int min = Integer.MAX_VALUE;
		int count = -1;
		
		for(int i = 0;i < N ; i++) {
			c[i] = sc.nextInt();
			t[i] = sc.nextInt();
		}
		
		for(int i = 0; i < N ; i++){
		    if(min > c[i] && T >= t[i]){
		    min = Math.min(min,c[i]);
		    count = i;
			}
	    }
	
		if(count == -1){ System.out.println("TLE");}
		else{System.out.println(c[count]);}
    }
}