Submission #1089784

#TimeUsernameProblemLanguageResultExecution timeMemory
1089784LilPlutonXOR Sum (info1cup17_xorsum)C++14
7 / 100
1648 ms20560 KiB
#include <bits/stdc++.h> using namespace std; #define int long long void solve(){ int n; cin >> n; vector<int>pr(n + 1, 0), a(n); for(int i = 0; i < n; ++i){ cin >> a[i]; pr[i + 1] = pr[i] + a[i]; } int res = 0; for(int i = 1; i <= n; ++i){ for(int j = i; j <= n; ++j){ int f = a[i - 1] + a[j - 1]; res ^= f; } } cout << res << endl; } signed main(){ int t = 1; while(t--){ solve(); } }
#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...