Submission #363341

# Submission time Handle Problem Language Result Execution time Memory
363341 2021-02-05T15:32:27 Z mosiashvililuka CONSUL (info1cup19_consul) C++14
0 / 100
2 ms 364 KB
#include <bits/stdc++.h>
#include "grader.h"

using namespace std;
int a,b,c,d,e,i,j,ii,jj,zx,xc,Q,t,tes,f[200009],bo[200009];
/*int kth(int k);
void say_answer(int k);
int cnt(int k);*/
int nicerand(int q){
	int w=0,we=1;
	while(q>0){
		q--;
		if(rand()%2!=0) w+=we;
		we*=2;
	}
	return w;
}
void solve(int n)
{
    /// insert your code
    /// for example
    /*if(cnt(kth(1)) > n / 3) say_answer(kth(1));
        else say_answer(-1);*/
    a=n;
    if(n<=50) Q=50; else Q=60;
    e=0;
    while(e<=Q){
    	c=nicerand(20)%a+1;
    	e+=2;
    	zx=kth(c);
    	xc=cnt(zx);
    	if(xc>a/3){
    		say_answer(zx);
		}
	}
}
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 364 KB Multiple answers provided for the same testcase!
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 364 KB Multiple answers provided for the same testcase!
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 2 ms 364 KB Multiple answers provided for the same testcase!
2 Halted 0 ms 0 KB -