Submission #1012737

#TimeUsernameProblemLanguageResultExecution timeMemory
1012737kachim2Football (info1cup20_football)C++17
0 / 100
22 ms2140 KiB
#include<bits/stdc++.h> using namespace std; bool sol(){ int n; int k; cin >> n; cin >> k; vector<int> a(n); for(int i = 0; i < n; i++) cin >> a[i]; int acc = accumulate(a.begin(), a.end(), 0); while(acc!=0){ if(acc&1) return 1; for(int &i : a) i/=2; acc = accumulate(a.begin(), a.end(), 0); } return 0; } int main(){ cin.tie(0); ios_base::sync_with_stdio(0); cout.tie(0); int t; cin >> t; for(int i = 0; i < t; i++){ cout << ((sol()) ? "1" : "0") ;//<< '\n'; } }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...