Submission #838654

#TimeUsernameProblemLanguageResultExecution timeMemory
838654vjudge1Akcija (COCI15_akcija)C++17
32 / 80
13 ms1660 KiB
#include <bits/stdc++.h> using namespace std; #define int long long #define OYY 1000000005 #define mod 998244353 #define faster ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL); #define mid (start+end)/2 int32_t main(){ faster int n;cin>>n; int dizi[n]; for(int i=0;i<n;i++)cin>>dizi[i]; sort(dizi,dizi+n); int cev=0; for(int i=0;i<n;i++){ if(i%3==0)continue; cev+=dizi[i]; } cout<<cev<<'\n'; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...