N, T = STDIN.gets.chomp.split(" ").map(&:to_i)

minimal_cost = nil

N.times do
  ci, ti = STDIN.gets.chomp.split(" ").map(&:to_i)

  if ti <= T 
    if minimal_cost.nil?
      minimal_cost = ci
    else
      minimal_cost = [minimal_cost, ci].min
    end
  end
end

if minimal_cost.nil?
  puts "TLE"
else
  puts minimal_cost
end
