제출 #1056145

#제출 시각아이디문제언어결과실행 시간메모리
1056145Gangsta도로 폐쇄 (APIO21_roads)C++14
5 / 100
27 ms5072 KiB
#include <bits/stdc++.h> #define ll long long int #define pb push_back using namespace std; vector<ll> minimum_closure_costs(int n, vector<int> u, vector<int> v, vector<int> w){ vector <ll> s, ans; ll sum = 0, san = 0; for(auto i: w){ s.pb(i); sum += i; } sort(s.rbegin(), s.rend()); ans.pb(sum); for(auto i: s){ san += i; ans.pb(sum-san); } return ans; }
#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...
#Verdict Execution timeMemoryGrader output
Fetching results...