Submission #464432

# Submission time Handle Problem Language Result Execution time Memory
464432 2021-08-13T08:33:39 Z Khizri Password (RMI18_password) C++17
0 / 100
268 ms 200 KB
//#include "grader.cpp"
#include <bits/stdc++.h>
using namespace std;
int query(string str);
string guess(int n, int ss){
	string s="";
	for(int i=1;i<=n;i++){
		s+='a';
	}
	for(int i=1;i<=n;i++){
		bool q=true;
		for(char c='a',k=1;k<=ss;k++,c++){
			s[i-1]=c;
			if(query(s)==i+1){
				q=false;
				break;
			}
		}
		if(q){
			for(char c='a',k=1;k<=ss;k++,c++){
				s[i-1]=c;
				if(query(s)==i){
					break;
				}
			}
		}
	}
	return s;
}
# Verdict Execution time Memory Grader output
1 Incorrect 6 ms 200 KB Returned early from guess() after 345 queries.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 3 ms 200 KB Returned early from guess() after 201 queries.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 268 ms 200 KB Returned early from guess() after 23101 queries.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 6 ms 200 KB Returned early from guess() after 345 queries.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 6 ms 200 KB Returned early from guess() after 345 queries.
2 Halted 0 ms 0 KB -