Submission #483994

# Submission time Handle Problem Language Result Execution time Memory
483994 2021-11-01T19:24:40 Z nickmet2004 COCI17_cezar (COCI17_cezar) C++11
20 / 50
1 ms 204 KB
#include<bits/stdc++.h>
using namespace std;
int a[53] , A[10000];
int main (){
    ios_base::sync_with_stdio(0); cin.tie(0);
    int n;
    cin >> n;
    int s = 0;
    for(int i = 0;i < n; ++i)cin >> a[i] ,s += a[i];
    int x = 21 - s;
    for(int i = 2; i <= 11; ++i) A[i] = 4;
    A[10] = 16;
    for(int i = 10; i>1; --i) A[i] += A[i + 1];
    int F = A[x + 1];
    //cout << F << " F" << endl;

    int S = A[2] - A[max(2 , x+1)];
    for(int i = 0; i < n; ++i){
        if(a[i] < x)S--;
        else F--;
    }
    //cout << S << " S" << endl;
    if(F  >= S)cout << "DOSTA";
    else cout << "VUCI";
return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 0 ms 204 KB Output is correct
3 Incorrect 0 ms 204 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 0 ms 204 KB Output is correct
3 Correct 0 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 204 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 0 ms 204 KB Output is correct
3 Correct 0 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 204 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 204 KB Output is correct
2 Correct 0 ms 204 KB Output is correct
3 Incorrect 0 ms 204 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 204 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Incorrect 0 ms 204 KB Output isn't correct
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 0 ms 204 KB Output is correct
3 Correct 0 ms 204 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 204 KB Output is correct
2 Correct 0 ms 204 KB Output is correct
3 Correct 0 ms 204 KB Output is correct