Submission #307660

#TimeUsernameProblemLanguageResultExecution timeMemory
307660amunduzbaev선물상자 (IOI15_boxes)C++14
10 / 100
1 ms384 KiB
#include "boxes.h" #include <bits/stdc++.h> using namespace std; #define ll long long long long delivery(int n, int k, int m, int p[]) { ll ans=0; sort(p,p+n); if(k==1){ for(int i=0;i<n;i++){ int a=(p[i]<=m/2 ? p[i]:m-p[i]); ans+=2*a; } } return ans; }
#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...