Submission #389397

# Submission time Handle Problem Language Result Execution time Memory
389397 2021-04-14T03:56:15 Z casperwang XOR Sum (info1cup17_xorsum) C++14
7 / 100
1600 ms 600 KB
#include <bits/stdc++.h>
using namespace std;
#define debug(args...) kout("[ " + string(#args) + " ]", args)
void kout() { cerr << endl; }
template <class T, class ...U> void kout(T a, U ...b) { cerr << a << ' ',kout(b...); }
template <class T> void pary(T L, T R) { while (L != R) cerr << *L << " \n"[++L==R]; }

const int MAXN = 1000000;
int N;
int a[MAXN+1];
int ans;

signed main() {
	ios_base::sync_with_stdio(0), cin.tie(0);
	cin >> N;
	for (int i = 1; i <= N; i++) {
		cin >> a[i];
		for (int j = 1; j <= i; j++)
			ans ^= (a[i] + a[j]);
	}
	cout << ans << '\n';
	return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 5 ms 332 KB Output is correct
2 Correct 5 ms 336 KB Output is correct
# Verdict Execution time Memory Grader output
1 Execution timed out 1696 ms 516 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 1696 ms 516 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 5 ms 332 KB Output is correct
2 Correct 5 ms 336 KB Output is correct
3 Execution timed out 1698 ms 600 KB Time limit exceeded
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 5 ms 332 KB Output is correct
2 Correct 5 ms 336 KB Output is correct
3 Execution timed out 1696 ms 516 KB Time limit exceeded
4 Halted 0 ms 0 KB -