# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
160276 | MarcoMendoza1 | Combo (IOI18_combo) | C++14 | 0 ms | 0 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>
using namespace std;
string guess_sequence(){
int ax;
while(r.size()<(n-1)){
aux=r+arr[2]+r+arr[1]+arr[1]+r+arr[1]+arr[2]+r+arr[1]+arr[3];
ax=press(aux);
if(ax==r.size()){
r=r+arr[3];
}else if(ax==(r.size()+1)){
r=r+arr[2];
}else{
r=r+arr[1];
}
}
if(press(r+arr[1]+r+arr[2])==n){
if(press(r+arr[1])==n){
return r+arr[1];
}else{
return r+arr[2];
}
}else{
return r+arr[3];
}
}