Submission #49502

#TimeUsernameProblemLanguageResultExecution timeMemory
49502lcs147COCI17_cezar (COCI17_cezar)C++98
50 / 50
3 ms620 KiB
#include<bits/stdc++.h> using namespace std; int cont[110]; int main(){ int n; scanf("%d",&n); int soma=0; for(int i=2;i<=9;i++)cont[i]=4; cont[10]=4*4; cont[11]=4; while(n--){ int a; scanf("%d",&a); soma+=a; cont[a]--; } int dif=21-soma; int maior=0,menor=0; for(int i=2;i<=11;i++){ if(i> dif) maior+=cont[i]; else menor+=cont[i]; } if(maior>=menor)printf("DOSTA\n"); else printf("VUCI\n"); return 0; }

Compilation message (stderr)

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