Submission #2868

#TimeUsernameProblemLanguageResultExecution timeMemory
2868solveit속이기 (GA5_fake)C++98
100 / 100
0 ms1672 KiB
#include <iostream> #include <string> #include <math.h> #include <sstream> #include <cstdio> #include <algorithm> using namespace std; int N; int main() { int xorRes = 0, sum = 0, smallest = 1<<30; scanf("%d",&N); for(int i = 1;i<=N;i++) { int n; scanf("%d", &n); xorRes ^= n; sum += n; smallest = min(smallest, n); } if(xorRes == 0) printf("%d\n", sum - smallest); else printf("%d\n", 0); return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...