import java.util.Scanner;

public class Main {
  public static void main(String[] args) throws Exception {
    Scanner scanner = new Scanner(System.in);
    int N = scanner.nextInt();
    int T = scanner.nextInt();
    int ans = 1001;
    for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    }
    scanner.close();
    if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    }
  }
} import java.util.Scanner; Scanner java.util public class Main {
  public static void main(String[] args) throws Exception {
    Scanner scanner = new Scanner(System.in);
    int N = scanner.nextInt();
    int T = scanner.nextInt();
    int ans = 1001;
    for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    }
    scanner.close();
    if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    }
  }
} Main public static void main(String[] args) throws Exception {
    Scanner scanner = new Scanner(System.in);
    int N = scanner.nextInt();
    int T = scanner.nextInt();
    int ans = 1001;
    for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    }
    scanner.close();
    if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    }
  } main {
    Scanner scanner = new Scanner(System.in);
    int N = scanner.nextInt();
    int T = scanner.nextInt();
    int ans = 1001;
    for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    }
    scanner.close();
    if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    }
  } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int N = scanner.nextInt(); N scanner.nextInt() scanner.nextInt scanner int T = scanner.nextInt(); T scanner.nextInt() scanner.nextInt scanner int ans = 1001; ans 1001 for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    } {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    } int c = scanner.nextInt(); c scanner.nextInt() scanner.nextInt scanner int t = scanner.nextInt(); t scanner.nextInt() scanner.nextInt scanner if (t <= T && c < ans) ans = c; t <= T && c < ans t <= T t T c < ans c ans ans = c ans c scanner.close() scanner.close scanner if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    } ans == 1001 ans 1001 {
      System.out.println("TLE");
    } System.out.println("TLE") System.out.println System.out System System.out "TLE" {
      System.out.println(ans);
    } System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {
  public static void main(String[] args) throws Exception {
    Scanner scanner = new Scanner(System.in);
    int N = scanner.nextInt();
    int T = scanner.nextInt();
    int ans = 1001;
    for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    }
    scanner.close();
    if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    }
  }
} public class Main {
  public static void main(String[] args) throws Exception {
    Scanner scanner = new Scanner(System.in);
    int N = scanner.nextInt();
    int T = scanner.nextInt();
    int ans = 1001;
    for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    }
    scanner.close();
    if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    }
  }
} Main
import java.util.Scanner;

public class Main {
  public static void main(String[] args) throws Exception {
    Scanner scanner = new Scanner(System.in);
    int N = scanner.nextInt();
    int T = scanner.nextInt();
    int ans = 1001;
    for (int i = 0; i < N; i++) {
      int c = scanner.nextInt();
      int t = scanner.nextInt();
      if (t <= T && c < ans) ans = c;
    }
    scanner.close();
    if (ans == 1001) {
      System.out.println("TLE");
    } else {
      System.out.println(ans);
    }
  }
}