checker
unknown
c_cpp
2 years ago
423 B
8
Indexable
#include<bits/stdc++.h>
using namespace std;
int main(){
int n, m;
cin >> n>> m;
vector<int> a(n+1);
for(int i = 1; i <= n; i++){
cin >> a[i];
}
while(m--){
int x;
bool good = 0;
while(cin >> x && x!=0){
//cout << x << " " <<abs(x) << endl;
if(x*a[abs(x)]>0){
good = 1;
}
}
if(!good){
cout << "WA" << endl;
return 0;
}
}
cout << "correct!" << endl;
}Editor is loading...
Leave a Comment