Submission #85500

#TimeUsernameProblemLanguageResultExecution timeMemory
85500memetkagan44COCI17_cezar (COCI17_cezar)C++11
45 / 50
3 ms824 KiB
#include<bits/stdc++.h> using namespace std; int n,a,sum; multiset<int> ms; int main(){ scanf("%d",&n); for(int i=2;i<=11;i++) for(int j=1;j<=4;j++) ms.insert(i); for(int i=1;i<=3;i++) for(int j=1;j<=4;j++) ms.insert(10); for(int i=1;i<=n;i++){ scanf("%d",&a); ms.erase(a); sum+=a; } multiset<int>::iterator q=ms.upper_bound(21-sum); int dist=distance(q,ms.end()); //printf("%d\n",dist); printf("%s\n",(52-n-dist)>=dist ? "VUCI" : "DOSTA"); 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:14:14: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
         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...