Submission #1066017

#TimeUsernameProblemLanguageResultExecution timeMemory
1066017goduadzesabaCONSUL (info1cup19_consul)C++17
85 / 100
16 ms344 KiB
#include <bits/stdc++.h> #include "grader.h" using namespace std; void solve(int n){ map <int,bool> m; int x; srand(time(0)); int q=0; while (q<min(n,30)){ x=rand()%n+1; if (m[x]) continue; q++; m[x]=1; x=kth(x); if (cnt(x)>n/3){ say_answer(x); return; } } say_answer(-1); return; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...