Submission #45693

#TimeUsernameProblemLanguageResultExecution timeMemory
45693RayaBurong25_1Boxes with souvenirs (IOI15_boxes)C++17
10 / 100
2 ms376 KiB
#include "boxes.h" long long min(long long a, long long b) { return (a < b)?a:b; } long long delivery(int N, int K, int L, int p[]) { long long r = 0; int i; long long mn, mx; for (i = 0; i < N; i += K) { mn = p[i]; mx = p[min(i + K, N) - 1]; r += min(L, min(mx, L - mn)*2LL); } return r; }
#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...