number, baseTime = gets.chomp.split(" ").map(&:to_i)
bestCost = "TLE"
number.times do
  cost, t = gets.chomp.split(" ").map(&:to_i)
  bestCost = cost if(t <= baseTime &&(bestCost == "TLE" || bestCost > cost))
end
puts bestCost