import java.util.*

fun main(args: Array<String>) {
    val sc = Scanner(System.`in`)
    val N = sc.nextInt()
    val T = sc.nextInt()
    val ans = (1..N).map {
        val c = sc.nextInt()
        val t = sc.nextInt()
        if (t <= T) {
            c
        } else {
            Int.MAX_VALUE
        }
    }.min()
    println(if (ans == Int.MAX_VALUE) "TLE" else ans)
}
