fun main(arr:Array<String>) {
    val (n,t) = readLine()!!.split(" ").map { it.toInt() }
    val keiro = (1..n).map { readLine()!!.split(" ").map { it.toInt() }.let { Keiro(it[0], it[1]) } }.filter { it.time <= t }.sortedBy { it.cost }
    if(keiro.isEmpty()) {
        println("TLE")
    } else {
        println(keiro[0].cost)
    }
}

class Keiro(val cost:Int, val time:Int)
