답안 #523487

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
523487 2022-02-07T17:34:32 Z AGE CONSUL (info1cup19_consul) C++14
86.85 / 100
28 ms 200 KB
#include<bits/stdc++.h>
#include "grader.h" 
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);
 
}
# 결과 실행 시간 메모리 Grader output
1 Correct 12 ms 200 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Partially correct 23 ms 200 KB Output is partially correct
2 Correct 7 ms 200 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Partially correct 27 ms 200 KB Output is partially correct
2 Partially correct 28 ms 200 KB Output is partially correct
3 Correct 9 ms 200 KB Output is correct
4 Correct 7 ms 200 KB Output is correct
5 Partially correct 23 ms 200 KB Output is partially correct
6 Partially correct 25 ms 200 KB Output is partially correct
7 Partially correct 24 ms 200 KB Output is partially correct
8 Partially correct 18 ms 200 KB Output is partially correct
9 Partially correct 11 ms 200 KB Output is partially correct
10 Partially correct 23 ms 200 KB Output is partially correct
11 Partially correct 28 ms 200 KB Output is partially correct
12 Partially correct 25 ms 200 KB Output is partially correct
13 Partially correct 27 ms 200 KB Output is partially correct
14 Partially correct 22 ms 200 KB Output is partially correct