(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 #393111

#TimeUsernameProblemLanguageResultExecution timeMemory
393111JimmyZJXCoins (IOI17_coins)C++14
100 / 100
12 ms1452 KiB
#include <iostream> #include <fstream> #include <algorithm> #include <cstring> #include <climits> #include <cassert> #include <tuple> #include <queue> #include <stack> #include <vector> #include <map> #include <set> #include <string> #include <unordered_set> #include <unordered_map> using namespace std; typedef long long LL; typedef vector<int> Vi; typedef vector<LL> VL; typedef vector<bool> Vb; typedef vector<vector<int>> Vii; #define forR(i, n) for (int i = 0; i < (n); i++) int find_coin(Vi b) { int r = 0; forR(i, 64) { if (b[i] == 1) { r ^= i; } } return r; } Vi coin_flips(Vi b, int c) { int r = find_coin(b); int k = c ^ r; return Vi{ k }; } #ifdef TEST_LOCAL int main() { auto result = coin_flips(Vi{ 5, 1, 1, 3, 3, 5 }, 3); return 0; } #endif
#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...