Submission #252327

# Submission time Handle Problem Language Result Execution time Memory
252327 2020-07-25T09:34:16 Z SamAnd Languages (IOI10_languages) C++17
0 / 100
3138 ms 1096 KB
#include <bits/stdc++.h>
#include "grader.h"
#include "lang.h"
using namespace std;
const int N = 60;

const int m = 100;

map<int, int> s[N];
int ss[N];

void excerpt(int *E)
{
    double maxu = -1;
    int maxi = -1;
    for (int i = 0; i < N; ++i)
    {
        double q = 0;
        for (int j = 0; j < m; ++j)
        {
            if (s[i].find(E[j]) != s[i].end())
                q += (s[i][E[j]] / (double)(ss[i]));
        }
        if (q > maxu)
        {
            maxu = q;
            maxi = i;
        }
    }
    int u = language(maxi);
    ss[u]++;
    for (int j = 0; j < m; ++j)
    {
        s[u][E[j]]++;
    }
}
# Verdict Execution time Memory Grader output
1 Incorrect 3138 ms 1096 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Incorrect 3094 ms 976 KB Output isn't correct - 29.76%