-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCodeGladi.cpp
More file actions
40 lines (36 loc) · 737 Bytes
/
CodeGladi.cpp
File metadata and controls
40 lines (36 loc) · 737 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#include<iostream>
#include<vector>
#include<algorithm>
using namespace std;
int main(){
int T;cin>>T;
while(T--){
int flg=1;
int N;cin>>N;
vector<int> vil;
vector<int> plr;
for(int i=0;i<N;i++){
int power;cin>>power;
vil.push_back(power);
}
for(int i=0;i<N;i++){
int power;cin>>power;
plr.push_back(power);
}
sort(plr.begin(),plr.end());
sort(vil.begin(),vil.end());
for(int i = 0;i<N;i++){
if(vil[i]<plr[i]){
continue;
}
else{
flg = 0;
cout<<"LOSE"<<endl;
break;
}
}
if(flg==1){cout<<"WIN"<<endl;}
plr.clear();
vil.clear();
}
}