#include<iostream>
#include<cstdio>
using namespace std;
int main()
{
    int n,t;
    cin>>n>>t;
    int ans=1e9;
    while(n--)
    {
        int a,b;
        cin>>a>>b;
        if(b<=t) ans=min(ans,a);
    }
    if(ans==1e9) cout<<"TLE"<<endl;
    else cout<<ans<<endl;
}
