#include <iostream>
#include <random>
#include "grader.h"
using namespace std;
#define endl '\n'
void speed()
{
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
}
void solve(int n)
{
random_device rd;
mt19937 rng(rd());
uniform_int_distribution <int> d(1,n);
for(int step = 1; step<=30; step++)
{
int i=d(rng);
int candidate = kth(i);
int br=cnt(candidate);
if(br>n/3)
{
say_answer(candidate);
}
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |