# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
962595 | Mohamed_Kachef06 | Combo (IOI18_combo) | C++17 | 25 ms | 1216 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#include "combo.h"
//#include "grader.cpp"
using namespace std;
string guess_sequence(signed N){
char a[] = {'A' , 'B' , 'X' , 'Y'};
string s;
for (int i = 0 ; i < 4 ; i++) {if (press(s+a[i])) {s+=a[i]; break;}};
for (int i = 0 ; i < N-1 ; i++){
random_shuffle(a , a+4);
for (int j = 0 ; j < 4 ; j++) if (a[j] != s[0]) if (press(s+a[j]) > s.size()) {s+=a[j]; break;}
}
return s;
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |