object Main extends App {
	val Array(n, t) = scala.io.StdIn.readLine.split(" ").map(_.toInt)
	var ans = List[Int]()

	for(i<-0 until n){
		val Array(c, t1) = scala.io.StdIn.readLine.split(" ").map(_.toInt)
		if(t1 <= t) ans =  c :: ans
	}

	if(ans.size == 0) println("TLE")
	else println(ans.min)
}
