a, b = map(int, input().split())
if a == b:
    print("tie")
elif (a == 1 and b == 2) or (a == 2 and b == 3) or (a == 3 and b == 1):
    print("win")
else:
    print("lose")

/**************************************************************
	Problem: 1048
	User: fuyijun
	Language: Python
	Result: Accepted
	Time:79 ms
	Memory:34480 kb
****************************************************************/