Submission #903878

#TimeUsernameProblemLanguageResultExecution timeMemory
903878zhasynCombo (IOI18_combo)C++17
10 / 100
42 ms1464 KiB
#include "combo.h"
#include <bits/stdc++.h>
#define pb push_back
#define pf push_front
using namespace std;
#define F first
#define S second
typedef long long ll;
#define pii pair <int, int>
#define pll pair <ll, ll>
typedef long double ld;
const ll N = 2 * 1e5 + 10, len = 316;
const ll mod = 1e9 + 7;

ll um(ll a, ll b){
	return ((1LL * a * b) % mod + mod) % mod;
}
ll subr(ll a, ll b){
	return ((1LL * a - b) % mod + mod) % mod;
}
string guess_sequence(int n){
	string ans = "";
	string s = "ABXY";
	for(int i = 0; i < n; i++){
		for(int j = 0; j < 4; j++){
			int res = press(ans + s[j]);
			if(res == i + 1){
				ans += s[j];
				break;
			}
		}
	}
	return ans;
}
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...