Submission #825362

# Submission time Handle Problem Language Result Execution time Memory
825362 2023-08-14T18:38:01 Z Darren0724 CONSUL (info1cup19_consul) C++17
0 / 100
11 ms 236 KB
#include <bits/stdc++.h>
#include "grader.h"
using namespace std;
mt19937 rnd(chrono::steady_clock::now().time_since_epoch().count());
/*int kth(int p){
    cout<<"kth "<<p<<endl;
    int ans;cin>>ans;return ans;
}
int cnt(int p){
    cout<<"cnt "<<p<<endl;
    int ans;cin>>ans;return ans;
}
void say_answer(int k){}
*/
void solve(int n){
    int times=0;
    while(times<25){
        int p=rnd()%n+1;
        int t=kth(p);
        if(cnt(t)>n/3){
            say_answer(t);
            return;
        }
    }
    say_answer(-1);
}
# Verdict Execution time Memory Grader output
1 Incorrect 11 ms 236 KB Too many queries
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 6 ms 208 KB Too many queries
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 4 ms 208 KB Too many queries
2 Halted 0 ms 0 KB -