Submission #145042

#TimeUsernameProblemLanguageResultExecution timeMemory
145042bogdan_buzatuCOCI17_cezar (COCI17_cezar)C++14
50 / 50
11 ms376 KiB
#include <iostream> using namespace std; //ifstream fin("davor.in"); //ofstream fout("davor.out"); int n,val[100],s1,s2,s,rest,x; int main(){ for(int i=2;i<=11;i++){ val[i]=4; } val[10]*=4; cin>>n; for(int i=1;i<=n;i++){ cin>>x; val[x]--; s+=x; } rest=21-s; for(int i=1;i<=rest;i++){ s1+=val[i]; } for(int i=rest+1;i<=11;i++){ s2+=val[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...