(function (input) {
  'use strict';
  const lines = input.split('\n')
  const firstLine = lines[0].split(' ')
  const N = Number(firstLine[0])
  const T = Number(firstLine[1])

  let Max = 2000

  for (var i=1; i <= N ; i++) {
    const tmpline = lines[i].split(' ')
    const cost = Number(tmpline[0])
    const time = Number(tmpline[1])
    if ( time <= T && cost < Max) Max = cost
  }
  Max === 2000 ? console.log('TLE') : console.log(Max)
  
})(require("fs").readFileSync("stdin", 'utf8'));
