import java.util.*

fun main(args: Array<String>) {
	val scanner = Scanner(System.`in`)
	val n = scanner.nextLong()
	val t = scanner.nextLong()
	val ct = mutableListOf<Pair<Long, Long>>()
	for (i in 1..n)
		ct.add(scanner.nextLong() to scanner.nextLong())
	val result = ct.asSequence()
			.filter { it.second <= t }
			.minBy { it.first }
	println(result?.first ?: "TLE")
}