# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
307183 | FelixMP | Stations (IOI20_stations) | C++14 | 985 ms | 1196 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 "stations.h"
#include <vector>
#include <algorithm>
#include <utility>
#include <iostream>
using namespace std;
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef pair<int, int> ii;
vvi al;
vi rans;
int ft = 0;
ii dfs(int v, int p, int r) {
int cmin = 1002;
int cmax = -1;
for(int i=0; i < (int)al[v].size(); ++i) {
int u = al[v][i];
if(u == p) continue;
ii x = dfs(u, v, !r);
//cerr << "VISITED " << u << " returned " << x.first << " " << x.second << endl;
cmin = min(cmin, x.first);
cmax = max(cmax, x.second);
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |