# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
464412 | 2021-08-13T07:08:51 Z | fuad27 | Password (RMI18_password) | C++14 | 138 ms | 408 KB |
#include<bits/stdc++.h> using namespace std; typedef long long ll; typedef long double ld; #define vii vector<pair<int, int>> #define vi vector<int> #define vl vector<long long> #define vll vector<pair<long long, long long>> #define mp make_pair #define pb push_back #define rep(i, a, b) for(int i = a;i<=b;i++) #define f first #define s second #define FIO ios_base::sync_with_stdio(0);cin.tie(0); #define start int tt;cin>>tt;rep(testcase, 1, tt) #define print(k) cout<<"Case #"<<testcase<<": "<<k<<"\n"; #define endl "\n" int query(string s); string guess(int n, int s) { string ans = ""; int pref = 0; bool check = false; rep(i, 0, n-1) { ans+="a"; for(char c = 'a';c<'a' + s;c++) { ans[i] = c; int g = query(ans); if(g >= i+1) { check = true; pref = g; break; } } } return ans; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 3 ms | 200 KB | Returned early from guess() after 187 queries. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 200 KB | Returned early from guess() after 77 queries. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 138 ms | 408 KB | Returned early from guess() after 11504 queries. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 3 ms | 200 KB | Returned early from guess() after 187 queries. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 3 ms | 200 KB | Returned early from guess() after 187 queries. |
2 | Halted | 0 ms | 0 KB | - |