Imports System.Collections.Generic
Imports System.Console

Module Program
    Sub Main()
        Dim N As Integer = NextInt()
        Dim T As Integer = NextInt()
        Dim TLE As Boolean = True
        Dim cost As Integer = Integer.MaxValue

        For i As Integer = 0 To N - 1
            Dim ci As Integer = NextInt()
            Dim ti As Integer = NextInt()

            If ti <= T AndAlso ci < cost Then
                cost = ci
                TLE = False
            End If
        Next

        If TLE Then
            WriteLine("TLE")
        Else
            WriteLine(cost)
        End If
    End Sub

    Function NextInt() As Integer
        Return CInt(NextString())
    End Function

    Function NextString() As String
        Dim result As New List(Of Char)
        Do
            Dim tmp As Integer = Read()
            If tmp < 0 Then Exit Do
            Dim nextChar As Char = Chr(tmp)

            If Not Char.IsWhiteSpace(nextChar) Then
                result.Add(nextChar)
            ElseIf nextChar <> vbCr Then
                Exit Do
            End If
        Loop
        Return New String(result.ToArray())
    End Function

End Module
