Submission #250201

#TimeUsernameProblemLanguageResultExecution timeMemory
250201Vladikus004COCI17_cezar (COCI17_cezar)C++14
50 / 50
1 ms396 KiB
#include <bits/stdc++.h> #define inf 2e9 #define all(v) v.begin(), v.end() using namespace std; typedef long long ll; typedef long double ld; typedef pair <int, int> pii; int n, cnt[20]; int main() { ios_base::sync_with_stdio(false); cin.tie(0); #ifdef LOCAL freopen("input.txt", "r", stdin); #endif // LOCAL for (int i = 2; i <= 10; i++){ cnt[i] = 4; } cnt[10] += 12; cnt[11] = 4; cin >> n; int sum = 0, ost = 0; for (int i = 0; i < n; i++){ int x; cin >> x; sum += x; } ost = 21 - sum; int s1 = 0, s2 = 0; for (int i = 2; i <= ost; i++){ s1 += cnt[i]; } for (int i = ost + 1; i <= 11; i++){ s2 += cnt[i]; } if (s1 > s2){ cout << "VUCI"; }else{ cout << "DOSTA"; } }
#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...