This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include<iostream>
using namespace std;
int n,x,bune,rele;
int f[]={0,4,4,4,4,4,4,4,4,4,16,4};
int main(){
cin>>n;
int suma=0;
for(int i=1;i<=n;i++){
cin>>x;
suma+=x;
f[x]--;
}
int rest=21-suma;
bune=rele=0;
for(int i=1;i<=11;i++){
if(i<=rest){
bune+=f[i];
}
else{
rele+=f[i];
}
}
if(bune>=rele){
cout<<"VUCI";
}
else{
cout<<"DOSTA";
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |