Submission #472703

#TimeUsernameProblemLanguageResultExecution timeMemory
472703SaraMostafaCOCI17_cezar (COCI17_cezar)C++14
35 / 50
1 ms312 KiB
#include <bits/stdc++.h> #include<unordered_map> using namespace std; #define ll long long #define endl "\n" #define Sara ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL); const long long mod=998244353; const double PI=acos(-1); int main() { //freopen("input.in","r",stdin); Sara int n; cin>>n; vector<int>v(n); ll sum=0; vector<ll>c(12,4); vector<ll>d(12,4); for(int i=0; i<n; i++) { cin>>v[i]; c[v[i]]--; sum+=v[i]; } ll x=21-sum; if(x<=0) cout<<"DOSTA"<<endl; else { ll b=0; for(int i=x+1; i<=11; i++) { b+=c[i]; } ll s=0; for(int i=1; i<=x; i++) { s+=c[i]; } if(b>=s) cout<<"DOSTA"<<endl; else cout<<"VUCI"<<endl; } return 0; }
#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...