Submission #777163

# Submission time Handle Problem Language Result Execution time Memory
777163 2023-07-08T18:17:09 Z LeaRouse CONSUL (info1cup19_consul) C++14
19 / 100
679 ms 208 KB
#include "grader.h"
#include    <map>
#define ll long long
using namespace std;
map<ll,int>m;
void solve(int n){
    for(int i=1;i<=n;i++){
        int a=kth(i);
        m[a]++;
    }
    for(auto it:m){
        if(it.second>(n/3)){
            m.clear();
            say_answer(it.first);
            return;
        }
    }
    m.clear();
    say_answer(-1); 
}
# Verdict Execution time Memory Grader output
1 Correct 33 ms 208 KB Output is correct
# Verdict Execution time Memory Grader output
1 Partially correct 60 ms 208 KB Output is partially correct
2 Partially correct 52 ms 208 KB Output is partially correct
# Verdict Execution time Memory Grader output
1 Partially correct 679 ms 208 KB Output is partially correct
2 Halted 0 ms 0 KB -