Submission #278831

#TimeUsernameProblemLanguageResultExecution timeMemory
278831amallaCombo (IOI18_combo)C++17
5 / 100
94 ms276 KiB
#include "combo.h" #include<bits/stdc++.h> using namespace std; string guess_sequence(int N) { string p = "", Moves = "ABXY", test; for (int i = 0; i < N; ++i) { p += 'A'; } test = p; int coins = press(p); for (int i = 0; i<N; ++i) { for (int j = 0; j<4; ++j) { test[i] = Moves[j]; if (coins<press(test)) { p[i] = Moves[j]; ++coins; break; } } test[i] = p[i]; } return p; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...