이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
#define ll long long
#define in insert
#define pb push_back
#define vl vector<ll>
#define endl "\n"
#define all(v) v.begin(),v.end()
#define speed ios_base::sync_with_stdio(false);cin.tie(0);
#define F first
#define S second
using namespace std;
const int sz = 2e5+5;
int main(){
speed;
ll t=1,n,k,i,sum=0;
cin>>t;
while(t--){sum=0;
cin>>n>>k;
vl v(n);
for(i=0;i<n;i++){
cin>>v[i];sum+=v[i];
}
if(sum%2==1){
cout<<1;
}
else{
cout<<0;
}
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |