import java.lang.*;
import java.io.*;
import java.util.*;

class Main{
	public static void main(String args[]) throws Exception{
		FScanner sc=new FScanner();
		int[] arg=sc.readIntL();
		int n=arg[0];
		int t=arg[1];
		
		int[][] path=new int[n][2];
		int[] buf=new int[2];
		for(int i=0; i<n; i++){
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		}
		
		int mx=1001;
		
		for(int i=0; i<n; i++){
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		}
		System.out.println((mx==1001)? "TLE": mx);
	}
	
	static void solve(int cur, int nx, int en, int hld){}

	static void disp(int[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	}
	
	static void disp(String[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%s ",data[i]);
		}
			System.out.println();
	}
	
	static void disp(long[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	}
	
	static class FScanner{
		BufferedReader read=null;
		StringTokenizer tok=null;
		Scanner sc;
		FScanner() throws FileNotFoundException{
			sc=new Scanner(System.in);
		}
		boolean hasNextLine(){
			boolean has=true;
			if(!sc.hasNextLine()){
				has=false;
			}
			return has;
		}
		int readInt(){
			String buf=sc.nextLine();
			return Integer.parseInt(buf);
		}
		long readLong(){
			long i=Long.parseLong(sc.nextLine());
			return i;
		}
		int[] readIntL(){
			String[] buf=sc.nextLine().split(" ");
			int[] num=new int[buf.length];
			for(int i=0; i<buf.length; i++){
				num[i]=Integer.parseInt(buf[i]);
			}
			return num;
		}
		
		String readString(){
			return sc.nextLine();
		}
		String[] readStringL(String dlm){
			String[] s=sc.nextLine().split(dlm);
			return s;
		}
	}
} import java.lang.*; lang.* java import java.io.*; io.* java import java.util.*; util.* java class Main{
	public static void main(String args[]) throws Exception{
		FScanner sc=new FScanner();
		int[] arg=sc.readIntL();
		int n=arg[0];
		int t=arg[1];
		
		int[][] path=new int[n][2];
		int[] buf=new int[2];
		for(int i=0; i<n; i++){
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		}
		
		int mx=1001;
		
		for(int i=0; i<n; i++){
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		}
		System.out.println((mx==1001)? "TLE": mx);
	}
	
	static void solve(int cur, int nx, int en, int hld){}

	static void disp(int[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	}
	
	static void disp(String[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%s ",data[i]);
		}
			System.out.println();
	}
	
	static void disp(long[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	}
	
	static class FScanner{
		BufferedReader read=null;
		StringTokenizer tok=null;
		Scanner sc;
		FScanner() throws FileNotFoundException{
			sc=new Scanner(System.in);
		}
		boolean hasNextLine(){
			boolean has=true;
			if(!sc.hasNextLine()){
				has=false;
			}
			return has;
		}
		int readInt(){
			String buf=sc.nextLine();
			return Integer.parseInt(buf);
		}
		long readLong(){
			long i=Long.parseLong(sc.nextLine());
			return i;
		}
		int[] readIntL(){
			String[] buf=sc.nextLine().split(" ");
			int[] num=new int[buf.length];
			for(int i=0; i<buf.length; i++){
				num[i]=Integer.parseInt(buf[i]);
			}
			return num;
		}
		
		String readString(){
			return sc.nextLine();
		}
		String[] readStringL(String dlm){
			String[] s=sc.nextLine().split(dlm);
			return s;
		}
	}
} Main public static void main(String args[]) throws Exception{
		FScanner sc=new FScanner();
		int[] arg=sc.readIntL();
		int n=arg[0];
		int t=arg[1];
		
		int[][] path=new int[n][2];
		int[] buf=new int[2];
		for(int i=0; i<n; i++){
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		}
		
		int mx=1001;
		
		for(int i=0; i<n; i++){
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		}
		System.out.println((mx==1001)? "TLE": mx);
	} main {
		FScanner sc=new FScanner();
		int[] arg=sc.readIntL();
		int n=arg[0];
		int t=arg[1];
		
		int[][] path=new int[n][2];
		int[] buf=new int[2];
		for(int i=0; i<n; i++){
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		}
		
		int mx=1001;
		
		for(int i=0; i<n; i++){
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		}
		System.out.println((mx==1001)? "TLE": mx);
	} FScanner sc=new FScanner(); sc new FScanner() int[] arg=sc.readIntL(); arg sc.readIntL() sc.readIntL sc int n=arg[0]; n arg[0] arg 0 int t=arg[1]; t arg[1] arg 1 int[][] path=new int[n][2]; path new int[n][2] n 2 int[] buf=new int[2]; buf new int[2] 2 for(int i=0; i<n; i++){
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		} int i=0; int i=0; i 0 i<n i n i++ i++ i {
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		} {
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		} buf=sc.readIntL() buf sc.readIntL() sc.readIntL sc path[i][0]=buf[0] path[i][0] path[i] path i 0 buf[0] buf 0 path[i][1]=buf[1] path[i][1] path[i] path i 1 buf[1] buf 1 int mx=1001; mx 1001 for(int i=0; i<n; i++){
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		} int i=0; int i=0; i 0 i<n i n i++ i++ i {
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		} {
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		} if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			} path[i][0]<mx && path[i][1]<=t path[i][0]<mx path[i][0] path[i] path i 0 mx path[i][1]<=t path[i][1] path[i] path i 1 t {
				mx=path[i][0];
			} mx=path[i][0] mx path[i][0] path[i] path i 0 System.out.println((mx==1001)? "TLE": mx) System.out.println System.out System System.out (mx==1001)? "TLE": mx (mx==1001) mx 1001 "TLE" mx String args[] args static void solve(int cur, int nx, int en, int hld){} solve {} int cur cur int nx nx int en en int hld hld static void disp(int[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	} disp {
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	} for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		} int i=0; int i=0; i 0 i<data.length i data.length data data.length i++ i++ i {
				System.out.printf("%d ",data[i]);
		} {
				System.out.printf("%d ",data[i]);
		} System.out.printf("%d ",data[i]) System.out.printf System.out System System.out "%d " data[i] data i System.out.println() System.out.println System.out System System.out int[] data data static void disp(String[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%s ",data[i]);
		}
			System.out.println();
	} disp {
		for(int i=0; i<data.length; i++){
				System.out.printf("%s ",data[i]);
		}
			System.out.println();
	} for(int i=0; i<data.length; i++){
				System.out.printf("%s ",data[i]);
		} int i=0; int i=0; i 0 i<data.length i data.length data data.length i++ i++ i {
				System.out.printf("%s ",data[i]);
		} {
				System.out.printf("%s ",data[i]);
		} System.out.printf("%s ",data[i]) System.out.printf System.out System System.out "%s " data[i] data i System.out.println() System.out.println System.out System System.out String[] data data static void disp(long[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	} disp {
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	} for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		} int i=0; int i=0; i 0 i<data.length i data.length data data.length i++ i++ i {
				System.out.printf("%d ",data[i]);
		} {
				System.out.printf("%d ",data[i]);
		} System.out.printf("%d ",data[i]) System.out.printf System.out System System.out "%d " data[i] data i System.out.println() System.out.println System.out System System.out long[] data data static class FScanner{
		BufferedReader read=null;
		StringTokenizer tok=null;
		Scanner sc;
		FScanner() throws FileNotFoundException{
			sc=new Scanner(System.in);
		}
		boolean hasNextLine(){
			boolean has=true;
			if(!sc.hasNextLine()){
				has=false;
			}
			return has;
		}
		int readInt(){
			String buf=sc.nextLine();
			return Integer.parseInt(buf);
		}
		long readLong(){
			long i=Long.parseLong(sc.nextLine());
			return i;
		}
		int[] readIntL(){
			String[] buf=sc.nextLine().split(" ");
			int[] num=new int[buf.length];
			for(int i=0; i<buf.length; i++){
				num[i]=Integer.parseInt(buf[i]);
			}
			return num;
		}
		
		String readString(){
			return sc.nextLine();
		}
		String[] readStringL(String dlm){
			String[] s=sc.nextLine().split(dlm);
			return s;
		}
	} FScanner BufferedReader read=null; read null StringTokenizer tok=null; tok null Scanner sc; sc FScanner() throws FileNotFoundException{
			sc=new Scanner(System.in);
		} FScanner {
			sc=new Scanner(System.in);
		} sc=new Scanner(System.in) sc new Scanner(System.in) boolean hasNextLine(){
			boolean has=true;
			if(!sc.hasNextLine()){
				has=false;
			}
			return has;
		} hasNextLine {
			boolean has=true;
			if(!sc.hasNextLine()){
				has=false;
			}
			return has;
		} boolean has=true; has true if(!sc.hasNextLine()){
				has=false;
			} !sc.hasNextLine() sc.hasNextLine() sc.hasNextLine sc {
				has=false;
			} has=false has false return has; has int readInt(){
			String buf=sc.nextLine();
			return Integer.parseInt(buf);
		} readInt {
			String buf=sc.nextLine();
			return Integer.parseInt(buf);
		} String buf=sc.nextLine(); buf sc.nextLine() sc.nextLine sc return Integer.parseInt(buf); Integer.parseInt(buf) Integer.parseInt Integer buf long readLong(){
			long i=Long.parseLong(sc.nextLine());
			return i;
		} readLong {
			long i=Long.parseLong(sc.nextLine());
			return i;
		} long i=Long.parseLong(sc.nextLine()); i Long.parseLong(sc.nextLine()) Long.parseLong Long sc.nextLine() sc.nextLine sc return i; i int[] readIntL(){
			String[] buf=sc.nextLine().split(" ");
			int[] num=new int[buf.length];
			for(int i=0; i<buf.length; i++){
				num[i]=Integer.parseInt(buf[i]);
			}
			return num;
		} readIntL {
			String[] buf=sc.nextLine().split(" ");
			int[] num=new int[buf.length];
			for(int i=0; i<buf.length; i++){
				num[i]=Integer.parseInt(buf[i]);
			}
			return num;
		} String[] buf=sc.nextLine().split(" "); buf sc.nextLine().split(" ") sc.nextLine().split sc.nextLine() sc.nextLine sc " " int[] num=new int[buf.length]; num new int[buf.length] buf.length buf buf.length for(int i=0; i<buf.length; i++){
				num[i]=Integer.parseInt(buf[i]);
			} int i=0; int i=0; i 0 i<buf.length i buf.length buf buf.length i++ i++ i {
				num[i]=Integer.parseInt(buf[i]);
			} {
				num[i]=Integer.parseInt(buf[i]);
			} num[i]=Integer.parseInt(buf[i]) num[i] num i Integer.parseInt(buf[i]) Integer.parseInt Integer buf[i] buf i return num; num String readString(){
			return sc.nextLine();
		} readString {
			return sc.nextLine();
		} return sc.nextLine(); sc.nextLine() sc.nextLine sc String[] readStringL(String dlm){
			String[] s=sc.nextLine().split(dlm);
			return s;
		} readStringL {
			String[] s=sc.nextLine().split(dlm);
			return s;
		} String[] s=sc.nextLine().split(dlm); s sc.nextLine().split(dlm) sc.nextLine().split sc.nextLine() sc.nextLine sc dlm return s; s String dlm dlm
import java.lang.*;
import java.io.*;
import java.util.*;

class Main{
	public static void main(String args[]) throws Exception{
		FScanner sc=new FScanner();
		int[] arg=sc.readIntL();
		int n=arg[0];
		int t=arg[1];
		
		int[][] path=new int[n][2];
		int[] buf=new int[2];
		for(int i=0; i<n; i++){
			buf=sc.readIntL();
			path[i][0]=buf[0];
			path[i][1]=buf[1];
		}
		
		int mx=1001;
		
		for(int i=0; i<n; i++){
			if(path[i][0]<mx && path[i][1]<=t){
				mx=path[i][0];
			}
		}
		System.out.println((mx==1001)? "TLE": mx);
	}
	
	static void solve(int cur, int nx, int en, int hld){}

	static void disp(int[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	}
	
	static void disp(String[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%s ",data[i]);
		}
			System.out.println();
	}
	
	static void disp(long[] data){
		for(int i=0; i<data.length; i++){
				System.out.printf("%d ",data[i]);
		}
			System.out.println();
	}
	
	static class FScanner{
		BufferedReader read=null;
		StringTokenizer tok=null;
		Scanner sc;
		FScanner() throws FileNotFoundException{
			sc=new Scanner(System.in);
		}
		boolean hasNextLine(){
			boolean has=true;
			if(!sc.hasNextLine()){
				has=false;
			}
			return has;
		}
		int readInt(){
			String buf=sc.nextLine();
			return Integer.parseInt(buf);
		}
		long readLong(){
			long i=Long.parseLong(sc.nextLine());
			return i;
		}
		int[] readIntL(){
			String[] buf=sc.nextLine().split(" ");
			int[] num=new int[buf.length];
			for(int i=0; i<buf.length; i++){
				num[i]=Integer.parseInt(buf[i]);
			}
			return num;
		}
		
		String readString(){
			return sc.nextLine();
		}
		String[] readStringL(String dlm){
			String[] s=sc.nextLine().split(dlm);
			return s;
		}
	}
}
