제출 #981624

#제출 시각아이디문제언어결과실행 시간메모리
981624MuhammadSaram도로 폐쇄 (APIO21_roads)C++17
0 / 100
30 ms3792 KiB
/********************* بسم الله الرحمن الرحيم ***********************/ /******************** ٱلْحَمْدُ لِلَّٰهِ رَبِّ ٱلْعَالَمِينَ *************************/ /******************* Prophet Muhammad صلى الله عليه وسلم ************/ /*********************** وَقُل رَّبِّ زِدْنِي عِلْمًا **************************/ #ifdef ONLINE_JUDGE #pragma GCC optimize("Ofast") #pragma GCC optimize("O3,unroll-loops") #pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt") #else #endif #include <bits/stdc++.h> #include "roads.h" using namespace std; // #define int long long #define endl '\n' #define in binary_search #define ll long long #define ld long double #define Hey ios::sync_with_stdio(false); #define Welcome cin.tie(NULL), cout.tie(NULL); #define all(v) v.begin(),v.end() #define rall(v) v.rbegin(), v.rend() vector<ll> minimum_closure_costs(int n,vector<int> u,vector<int> v,vector<int> w) { ll su=0; for (int i=0;i<n-1;i++) su+=w[i]; sort(rall(w)); vector<ll> ans; ans.push_back(su); for (int i=0;i<n-1;su-=w[i],i++) ans.push_back(su); 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...