#include <stdlib.h>
#include <stdio.h>
#include "grader.h"
#include "lang.h"
#include <bits/stdc++.h>
using namespace std;
template <class T1, class T2>
inline bool maximise(T1 &x, T2 y) {
if (x < y) { x = y; return true; }
return false;
}
const int LEN = 100;
const int NUM_LANG = 56;
set<int> alphabets[NUM_LANG];
void excerpt(int *txt) {
int best = -1, lang = -1;
for (int x = 0; x < NUM_LANG; x++) {
int cnt = 0;
for (int i = 0; i < LEN; i++)
if (alphabets[x].count(txt[i]))
cnt++;
if (maximise(best, cnt))
lang = x;
}
int ans = language(lang);
for (int i = 0; i < LEN; i++)
alphabets[ans].insert(txt[i]);
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1791 ms |
6300 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Partially correct |
1784 ms |
6296 KB |
Output is partially correct - 52.92% |