Submission #200892

#TimeUsernameProblemLanguageResultExecution timeMemory
200892SamAndCOCI17_cezar (COCI17_cezar)C++17
50 / 50
6 ms504 KiB
#include <bits/stdc++.h> using namespace std; const int N = 55; int n; int a[N]; int q[N]; int main() { for (int i = 2; i <= 10; ++i) q[i] = 4; q[10] += 12; q[11] = 4; scanf("%d", &n); int x = 0; for (int i = 1; i <= n; ++i) { scanf("%d", &a[i]); x += a[i]; --q[a[i]]; } x = (21 - x); int q1 = 0; for (int i = 2; i <= x; ++i) q1 += q[i]; int q2 = 0; for (int i = x + 1; i <= 11; ++i) q2 += q[i]; if (q1 > q2) printf("VUCI\n"); else printf("DOSTA\n"); return 0; }

Compilation message (stderr)

cezar.cpp: In function 'int main()':
cezar.cpp:16:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
     scanf("%d", &n);
     ~~~~~^~~~~~~~~~
cezar.cpp:20:14: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
         scanf("%d", &a[i]);
         ~~~~~^~~~~~~~~~~~~
#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...