제출 #668802

#제출 시각아이디문제언어결과실행 시간메모리
668802Astrayt선물상자 (IOI15_boxes)C++17
10 / 100
1 ms300 KiB
#include <bits/stdc++.h> using namespace std; #define ll long long ll delivery(int N, int K, int L, int pos[]){ if(K == 1){ ll ret = 0; for(int i = 0; i < N; ++i){ int dist = min(pos[i], L - pos[i]); ret += 2ll * dist; } return ret; } }

컴파일 시 표준 에러 (stderr) 메시지

boxes.cpp: In function 'long long int delivery(int, int, int, int*)':
boxes.cpp:14:1: warning: control reaches end of non-void function [-Wreturn-type]
   14 | }
      | ^
#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...