Submission #523486

# Submission time Handle Problem Language Result Execution time Memory
523486 2022-02-07T17:33:08 Z AGE CONSUL (info1cup19_consul) C++14
Compilation error
0 ms 0 KB
#include<bits/stdc++.h>
#include "grader.h"

#define int long long 
using namespace std;
void solve(int N){
int n=N;
map<int,int>mpp;
int cntt=min(N/2,(int)30);
    while(cntt>=0){
        int x=rand()%n;
        if(mpp[x])continue;
        int y=kth(x+1);
        int yy=cnt(y);
        if(yy>n/3){
            say_answer(y);
            return ;
        }
        mpp[x]=1;
        cntt--;
    }
    say_answer(-1);
 
}

Compilation message

/usr/bin/ld: /tmp/ccQY0xOA.o: in function `main':
grader.cpp:(.text.startup+0xa8): undefined reference to `solve(int)'
collect2: error: ld returned 1 exit status