Submission #54030

#TimeUsernameProblemLanguageResultExecution timeMemory
54030robertBoxes with souvenirs (IOI15_boxes)C++14
0 / 100
2 ms256 KiB
#include <iostream> using namespace std; int dtz(int a, int L){ return min(a, L-a); } int delivery(int N, int K, int L, int *p){ int ans = 0; for(int n=0; n<N; n++){ ans += dtz(p[n], L)*2; } return ans; }

Compilation message (stderr)

boxes.cpp: In function 'int delivery(int, int, int, int*)':
boxes.cpp:9:25: warning: unused parameter 'K' [-Wunused-parameter]
 int delivery(int N, int K, int L, int *p){
                         ^
#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...