#include <iostream>
using namespace std;
string a,b,c,d;
int main(){
cin>>a>>b;
if(ab){
d="tie";
}
else if(a"1" && b!="3" || a=="2" && b!="1" || a=="3" && b!="2" && c!="2")
d="win";
else if(b=="1" && a!="3" || b=="2" && a!="1" || b=="3" && a!="2" && c!="2")
d="lose";
else
d="tie";
cout<<d;
return 0;
}