# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
720426 | yellowtoad | CONSUL (info1cup19_consul) | C++17 | 0 ms | 0 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#include "grader.h"
void solve(int n) {
int tmp, cnnt = 0;
srand(time(NULL));
while ((cnnt < 30) || ((n <= 50) && (cnt < 25))) {
tmp = kth(rand()%n+1);
if (cnt(tmp) > n/3) {
say_answer(tmp);
return;
}
cnnt++;
}
say_answer(-1);
}