n,t = gets.split(" ").map(&:to_i)
minc = 1001
for i in 1..n do
    cost,time = gets.split(" ").map(&:to_i)
    if time <= t
        if cost <= minc
            minc = cost
        end
    end
end

if minc == 1001
    puts "TLE"
else
    puts minc
end