# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
1099778 | model_code | 나일강 (IOI24_nile) | C++17 | 0 ms | 0 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
// incorrect/arshia_sub2_heuristic.cpp
#include "nile.h"
#include <vector>
using namespace std;
vector<long long> calculate_costs(vector<int> W, vector<int> A, vector<int> B, vector<int> E) {
long long total = 0;
int n = W.size(), mn = INT_MAX;
for (int i = 0; i < n; i++) {
total += B[i];
mn = min(mn, A[i] - B[i]);
}
return vector<long long>(E.size(), n & 1 ? total + mn : total);
}