Submission #963208

#TimeUsernameProblemLanguageResultExecution timeMemory
963208SuPythonySwapping Cities (APIO20_swap)C++17
6 / 100
98 ms15800 KiB
#include "swap.h" #include <bits/stdc++.h> using namespace std; vector<vector<pair<int,int>>> al; int mx=0; int n,m; void init(int N, int M, vector<int> U, vector<int> V, vector<int> W) { al.assign(N+1,vector<pair<int,int>>()); for (int i=0; i<M; i++) { al[U[i]].push_back({V[i],W[i]}); al[V[i]].push_back({U[i],W[i]}); mx=max(mx,W[i]); } n=N; m=M; } int getMinimumFuelCapacity(int X, int Y) { if (m==n-1) return -1; return mx; }
#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...