Submission #1135628

#TimeUsernameProblemLanguageResultExecution timeMemory
1135628noodles0428Coins (IOI17_coins)C++20
0 / 100
1 ms580 KiB
#ifdef ONLINE_JUDGE #include "coins.h" #endif #include <bits/stdc++.h> using namespace std; #define pp pair <int, int> #define fi first #define se second #define yes cout << "YES\n" #define no cout << "NO\n" vector <int> coin_flips (vector <int> b, int c){ int state[2] = {(c == 0), (c == 1)}; int match = (state[0] == b[0]) + (state[1] == b[1]); if (match == 2) return vector <int> (); if (match == 1){ vector <int> vec; if (state[0] != b[0]) vec.push_back (0); if (state[1] != b[1]) vec.push_back (1); return vec; } if (c == 0){ vector <int> vec; if (b[0]) vec.push_back (0); if (b[1]) vec.push_back (1); return vec; } if (c == 1){ vector <int> vec; if (b[0] == 0) vec.push_back (0); if (b[1] == 0) vec.push_back (1); return vec; } return vector <int> (); } int find_coin (vector <int> b){ if (b[0] == 0 && b[1] == 0) return 0; if (b[0] && b[1]) return 1; if (b[0]) return 0; return 1; } // love you, noodles0428 <333 // voi25 3rd++
#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...