num, limit = gets.chomp.split(" ").map(&:to_i)
drafts = $stdin.readlines

drafts.map! do | draft | 
  draft.chomp!
  draft = draft.split(" ")
end

drafts.each do | draft |
  draft.map!(&:to_i)
end

costs = drafts.map do | draft |
  draft[0] if draft[1] <= limit
end

costs.compact!
if  costs.length != 0
  puts costs.min
else
  puts "TLE"
end
