N, T = gets.chomp.split(' ').map(&:to_i)
input = Array.new(N) { gets.chomp.split(' ').map(&:to_i) }
new_input = input.select do |item|
  item[1] <= T
end
if new_input.size == 0
  puts 'TLE'
  exit
end
new_new_input = Array.new
new_input.each do |item|
  new_new_input << item[0]
end
puts new_new_input.min
