#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #define rep(i,a) for(int i=(int)0;i<(int)a;++i) #define pb push_back #define eb emplace_back using ll=long long; constexpr ll mod = 1e9 + 7; constexpr ll INF = 1LL << 50; template inline bool chmin(T& a, T b) { if (a > b) { a = b; return true; } return false; } template inline bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; } using namespace std; bool dp[250000]; void solve(){ int p; cin>>p; int n,k; while(p--){ cin>>n>>k; memset(dp,false,sizeof(dp)); rep(i,k+1)dp[n+i]=true; for(int i=n-1;i>=0;--i){ for(int j=1;j<=k;++j){ dp[i]|=!dp[i+j]; } } if(dp[0])cout<<"Win\n"; else cout<<"Lose\n"; } } int main(){ ios::sync_with_stdio(false); cin.tie(0); cout<