import std.stdio, std.string, std.conv;
import std.typecons;
import std.algorithm, std.array, std.range, std.container;
import std.math;

void main() {
	auto data = readln.split;
	auto N = data[0].to!int, T = data[1].to!int;
	
	int cost = 10_000;
	foreach (i; 0 .. N) {
		data = readln.split;
		auto c = data[0].to!int, t = data[1].to!int;
		if (t <= T && c < cost) { cost = c; }
	}
	
	if (cost == 10_000) writeln("TLE");
	else writeln(cost);
}