Submission #383680

#TimeUsernameProblemLanguageResultExecution timeMemory
383680wlh_codeCombo (IOI18_combo)C++17
10 / 100
71 ms524 KiB
#include "combo.h" using namespace std; string guess_sequence (int N) { string keys = "ABXY"; string s; for (int i = 0; i < 4; ++i) { string t; t += keys[i]; if (press(t)) { s += keys[i]; keys.erase(keys.begin() + i); break; } } for (int i = 1; i < N; ++i) { for (int j = 0; j < 3; ++j) { string t = s; t += keys[j]; if (press(t) > i) { s += keys[j]; break; } } } return s; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...