#include <iostream>
using namespace std;
int main(){
int inf;
inf=1e9;
int N,T;cin >>N>>T;
int x=inf;
for(int i=1;i<=N;i++){
  int c,t;cin >>c>>t;
  if(t<=T){
    if(c<x){
      x=c;
    }
  }
}
if(x==inf){
  cout<<"TLE"<<endl;
}
else{
  cout <<x<<endl;
}
return 0;
}
