import java.util.*;

public class Main{

     public static void main(String []args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int t = sc.nextInt();
        
        int min = 1001;
        for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        }
        
        
        System.out.println(min>1000 ? "TLE" : min);
     }
} 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 t = sc.nextInt();
        
        int min = 1001;
        for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        }
        
        
        System.out.println(min>1000 ? "TLE" : min);
     }
} Main public static void main(String []args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int t = sc.nextInt();
        
        int min = 1001;
        for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        }
        
        
        System.out.println(min>1000 ? "TLE" : min);
     } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int t = sc.nextInt();
        
        int min = 1001;
        for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        }
        
        
        System.out.println(min>1000 ? "TLE" : min);
     } 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 min = 1001; min 1001 for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        } int i=0; int i=0; i 0 i<n i n i++ i++ i {
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        } {
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        } int c = sc.nextInt(); c sc.nextInt() sc.nextInt sc int time = sc.nextInt(); time sc.nextInt() sc.nextInt sc if(time<=t){
                min = Math.min(c, min);
            } time<=t time t {
                min = Math.min(c, min);
            } min = Math.min(c, min) min Math.min(c, min) Math.min Math c min System.out.println(min>1000 ? "TLE" : min) System.out.println System.out System System.out min>1000 ? "TLE" : min min>1000 min 1000 "TLE" min String []args args public class Main{

     public static void main(String []args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int t = sc.nextInt();
        
        int min = 1001;
        for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        }
        
        
        System.out.println(min>1000 ? "TLE" : min);
     }
} public class Main{

     public static void main(String []args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int t = sc.nextInt();
        
        int min = 1001;
        for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        }
        
        
        System.out.println(min>1000 ? "TLE" : min);
     }
} Main
import java.util.*;

public class Main{

     public static void main(String []args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int t = sc.nextInt();
        
        int min = 1001;
        for(int i=0;i<n;i++){
            int c = sc.nextInt();
            int time = sc.nextInt();
            
            if(time<=t){
                min = Math.min(c, min);
            }
        }
        
        
        System.out.println(min>1000 ? "TLE" : min);
     }
}