Submission #1009717

# Submission time Handle Problem Language Result Execution time Memory
1009717 2024-06-28T00:49:06 Z u_suck_o Languages (IOI10_languages) C++17
0 / 100
3 ms 604 KB
#include "bits/stdc++.h"
#include "lang.h"
#define C 65536

using namespace std;

int freq[56][C];
int cfreq[C];

int language(int L);

void excerpt(int E[]) {
    memset(cfreq, 0, sizeof cfreq);
    for (int i = 0; i < 100; i++) {
        cfreq[E[i]]++;
    }

    int maxcnt = 0, maxlang = -1;
    for (int l = 0; l < 56; l++) {
        int cnt = 0;
        for (int i = 0; i < C; i++) {
            if (cfreq[i] && freq[l][i])
                cnt++;
        }
        if (cnt > maxcnt) {
            maxcnt = cnt;
            maxlang = l;
        }
    }
    int lang = language(maxlang);
    for (int i = 0; i < C; i++)
        freq[lang][i] += cfreq[i];
}
# Verdict Execution time Memory Grader output
1 Incorrect 3 ms 604 KB Hacked.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 3 ms 604 KB Hacked.
2 Halted 0 ms 0 KB -