import java.util.*

object MainKt {
    @JvmStatic
    fun main(args: Array<String>) {
        val scanner = Scanner(System.`in`)
        val n = scanner.nextInt()
        val T = scanner.nextInt()

        var min = -1
        for (i in 0..n-1){
            val c = scanner.nextInt()
            val t = scanner.nextInt()

            if (t<=T) {
                if (min==-1) min = c
                else min = Math.min(min, c)
            }
        }

        println(if(min==-1) "TLE" else min)

    }
}