# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
788810 | Ronin13 | Crocodile's Underground City (IOI11_crocodile) | C++17 | 349 ms | 61016 KiB |
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 "crocodile.h"
#include <bits/stdc++.h>
#define ll long long
#define ull unsigned ll
#define f first
#define s second
#define pii pair<int,int>
#define pll pair<ll,ll>
#define pb push_back
#define epb emplace_back
using namespace std;
int travel_plan(int n, int m, int R[][2], int L[], int k, int p[])
{
vector <vector <pii> > g(n);
priority_queue <pii> pq;
for(int i = 0; i < m; i++){
int u = R[i][0];
int v = R[i][1];
int l = L[i];
g[v].pb({u, l});
g[u].pb({v, l});
}
int d[n + 1][2];
for(int i = 0; i < n; i++)
d[i][0] = d[i][1] = 1e9 + 1;
for(int i = 0; i < k; i++){
pq.push({0, p[i]});
d[p[i]][0] = d[p[i]][1] = 0;
}
vector <bool> used(n + 1, false);
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |