Submission #1021366

#TimeUsernameProblemLanguageResultExecution timeMemory
1021366Hamed_GhaffariCombo (IOI18_combo)C++17
10 / 100
47 ms952 KiB
#include <bits/stdc++.h> #include "combo.h" #define pb push_back using namespace std; string guess_sequence(int n) { string s=""; for(int i=1; i<=n; i++) { if(i==1 || s[0] != 'A') { s.pb('A'); if(press(s) == i) continue; s.pop_back(); } if(i==1 || s[0] != 'B') { s.pb('B'); if(press(s) == i) continue; s.pop_back(); } if(i==1 || s[0] != 'X') { s.pb('X'); if(press(s) == i) continue; s.pop_back(); } if(i==1 || s[0] != 'Y') { s.pb('Y'); if(press(s) == i) continue; s.pop_back(); } } return s; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...