N, T = gets.split.map!{|x| x.to_i}
input = Array.new

(0..(N - 1)).each do
  input << gets.split.map!{|x| x.to_i}
end

nominee = Array.new

input.each do |r|
  cost = r[0]
  time = r[1]

  nominee << [cost, time] if time <= T
end

result = nominee.map {|i| i[0]}.min

if result.nil?
  puts 'TLE'
else
  puts result
end