fun main(args: Array<String>) {
    val (n, t) = readLine()!!.split(" ").map(String::toInt)
    var cost: Int? = null
    for (i in 1..n) {
        val (c, u) = readLine()!!.split(" ").map(String::toInt)
        if (t < u) continue
        if (cost == null || c < cost) {
            cost = c
        }
    }
    println(if (cost == null) "TLE" else cost)
}
