이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include "wiring.h"
#include <bits/stdc++.h>
using namespace std;
#define sz(a) (int)a.size()
#define all(a) begin(a),end(a)
using ll = long long;
ll min_total_length(vector<int> a, vector<int> b) {
int n = sz(a), m = sz(b);
ll tot = accumulate(all(b),0ll);
tot-=1ll*m*a.back();
tot+=1ll*(n-1)*b[0];
tot-=accumulate(all(a)-1,0ll);
return tot;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |