fun main(args: Array<String>) {
  val (N,T) = readLine()!!.split(" ").map{it.toInt()}
  val roots = (1..N).map{
    readLine()!!.split(" ").map{it.toInt()}
  }.filter{ it[1] <= T }

  if(roots.minBy{it[0]}?.get(0) == null) {
    println("TLE")
  } else {
    println(roots.minBy{it[0]}!!.get(0))
  }
}