input = $stdin.readlines
tmp1=input[0].chomp.split
n=tmp1[0].to_i
tt=tmp1[1].to_i
result=0
for a in 1..n do
    tmp2=input[a].chomp.split
    c=tmp2[0].to_i
    t=tmp2[1].to_i
    if t<=tt then 
        if result>c then
          result=c
        end
        if result==0 then
          result=c
        end
    end
end
case result
  when 0 then
    puts 'TLE'
  else
    p result
end