import java.util.Scanner;

public class Main {
	public static void main (String[] args) {
		Scanner sc = new Scanner(System.in);
		// 入力
		int n = sc.nextInt();
		int t = sc.nextInt();

		int tmp = 9999;
		int min = 9999;
		int[] ci = new int[n];
		int[] ti = new int[n];
		int i = 0;
		for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		}

		// 出力
		if (min < 9999){
			System.out.println(min);
		} else {
			System.out.println("TLE");
		}
	}
} import java.util.Scanner; Scanner 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 tmp = 9999;
		int min = 9999;
		int[] ci = new int[n];
		int[] ti = new int[n];
		int i = 0;
		for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		}

		// 出力
		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 n = sc.nextInt();
		int t = sc.nextInt();

		int tmp = 9999;
		int min = 9999;
		int[] ci = new int[n];
		int[] ti = new int[n];
		int i = 0;
		for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		}

		// 出力
		if (min < 9999){
			System.out.println(min);
		} else {
			System.out.println("TLE");
		}
	} main {
		Scanner sc = new Scanner(System.in);
		// 入力
		int n = sc.nextInt();
		int t = sc.nextInt();

		int tmp = 9999;
		int min = 9999;
		int[] ci = new int[n];
		int[] ti = new int[n];
		int i = 0;
		for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		}

		// 出力
		if (min < 9999){
			System.out.println(min);
		} else {
			System.out.println("TLE");
		}
	} 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 tmp = 9999; tmp 9999 int min = 9999; min 9999 int[] ci = new int[n]; ci new int[n] n int[] ti = new int[n]; ti new int[n] n int i = 0; i 0 for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		} i = 0; i = 0 i 0 i < n i n i++ i++ i {
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		} {
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		} ci[i] = sc.nextInt() ci[i] ci i sc.nextInt() sc.nextInt sc ti[i] = sc.nextInt() ti[i] ti i sc.nextInt() sc.nextInt sc if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			} ti[i] <= t ti[i] ti i t {
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			} tmp = ci[i] tmp ci[i] ci i if (min > tmp){
					min = tmp;
				} min > tmp min tmp {
					min = tmp;
				} min = tmp min tmp 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 n = sc.nextInt();
		int t = sc.nextInt();

		int tmp = 9999;
		int min = 9999;
		int[] ci = new int[n];
		int[] ti = new int[n];
		int i = 0;
		for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		}

		// 出力
		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 n = sc.nextInt();
		int t = sc.nextInt();

		int tmp = 9999;
		int min = 9999;
		int[] ci = new int[n];
		int[] ti = new int[n];
		int i = 0;
		for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		}

		// 出力
		if (min < 9999){
			System.out.println(min);
		} else {
			System.out.println("TLE");
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main (String[] args) {
		Scanner sc = new Scanner(System.in);
		// 入力
		int n = sc.nextInt();
		int t = sc.nextInt();

		int tmp = 9999;
		int min = 9999;
		int[] ci = new int[n];
		int[] ti = new int[n];
		int i = 0;
		for (i = 0; i < n; i++){
			ci[i] = sc.nextInt();
			ti[i] = sc.nextInt();
			if (ti[i] <= t){
				tmp = ci[i];
				if (min > tmp){
					min = tmp;
				}
			}
		}

		// 出力
		if (min < 9999){
			System.out.println(min);
		} else {
			System.out.println("TLE");
		}
	}
}