Submission #409210

# Submission time Handle Problem Language Result Execution time Memory
409210 2021-05-20T11:05:03 Z snasibov05 COCI17_cezar (COCI17_cezar) C++14
50 / 50
1 ms 296 KB
#include <iostream>
#include <vector>

using namespace std;

int main() {
    vector<int> v(12);
    for (int i = 1; i < 12; ++i){
        v[i] = 4;
        if (i == 10) v[i] = 16;
    }

    int n; cin >> n;
    int sm = 0;
    for (int i = 0; i < n; ++i){
        int x; cin >> x;
        sm += x;
        v[x]--;
    }

    sm = 21 - sm;

    int a = 0, b = 0;
    for (int i = 1; i < 12; ++i){
        if (i <= sm) a += v[i];
        else b += v[i];
    }

    if (a > b) cout << "VUCI\n";
    else cout << "DOSTA\n";

    return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 296 KB Output is correct
3 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 292 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 292 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 1 ms 204 KB Output is correct
3 Correct 1 ms 204 KB Output is correct