This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include "roads.h"
#include <vector>
#include<algorithm>
using namespace std ;
vector<long long>v;
vector<long long> minimum_closure_costs(int N, vector<int> U,vector<int> V,vector<int> W) {
sort(W.begin(),W.end()); v.push_back(0);
v.push_back(W[0]);
for(int i=2;i<=N;i++)
v.push_back(v[i-1]+W[i-1]);
v.pop_back();
reverse(v.begin(),v.end());
return v;
}
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |