(UPD: 2024-12-04 14:48 UTC) Judge is not working due to Cloudflare incident. (URL) We can do nothing about it, sorry. After the incident is resolved, we will grade all submissions.

Submission #306237

#TimeUsernameProblemLanguageResultExecution timeMemory
306237peuchCoins (IOI17_coins)C++17
100 / 100
13 ms1896 KiB
#include "coins.h" std::vector<int> coin_flips(std::vector<int> b, int c) { std::vector<int> flips(1); int aux = 0; for(int i = 0; i < 6; i++){ int cnt = 0; for(int j = 0; j < 64; j++) if(j&(1<<i)) cnt ^= b[j]; aux |= (cnt<<i); } aux ^= c; flips[0] = aux; return flips; } int find_coin(std::vector<int> b) { int aux = 0; for(int i = 0; i < 6; i++){ int cnt = 0; for(int j = 0; j < 64; j++) if(j&(1<<i)) cnt ^= b[j]; aux |= (cnt<<i); } return aux; }
#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...