Submission #437708

#TimeUsernameProblemLanguageResultExecution timeMemory
437708ala2Road Closures (APIO21_roads)C++14
0 / 100
48 ms4096 KiB
#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) { int mn=1000000001; int n=N; for(int i=N-2;i>=0;i--) { mn=min(mn,W[i]); v.push_back(mn); } v.push_back(0); return v; }

Compilation message (stderr)

roads.cpp: In function 'std::vector<long long int> minimum_closure_costs(int, std::vector<int>, std::vector<int>, std::vector<int>)':
roads.cpp:8:38: warning: unused variable 'n' [-Wunused-variable]
    8 |              int mn=1000000001;  int n=N;
      |                                      ^
#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...