Submission #138547

#TimeUsernameProblemLanguageResultExecution timeMemory
138547KCSCCOCI17_cezar (COCI17_cezar)C++14
50 / 50
3 ms400 KiB
#include <bits/stdc++.h> using namespace std; const int DIM = 20; int val[DIM]; int main(void) { #ifdef HOME freopen("cezar.in", "r", stdin); freopen("cezar.out", "w", stdout); #endif for (int i = 2; i <= 10; ++i) val[i] = 4; val[10] += 12; val[11] += 4; int n; cin >> n; int sum = 21; while (n--) { int x; cin >> x; sum -= x; --val[x]; } int nr1 = 0; for (int i = sum + 1; i <= 11; ++i) nr1 += val[i]; int nr2 = 0; for (int i = 1; i <= sum; ++i) nr2 += val[i]; cout << (nr1 >= nr2 ? "DOSTA" : "VUCI") << endl; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...