# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
76075 | luciocf | Race (IOI11_race) | C++14 | 1731 ms | 143980 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.
// IOI 2011 - Race
// Lúcio Cardoso
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 2e5+10;
const int MAXD = 1e6+10;
const int MAXL = 20;
typedef pair<int, int> pii;
int n, k, size[MAXN], ans;
set<int> S[MAXD];
bool mark[MAXN];
vector<pii> grafo[MAXN];
int DFS(int u, int p)
{
size[u] = 1;
for (int i = 0; i < (int) grafo[u].size(); i++)
{
int v = grafo[u][i].first;
if (v == p || mark[v]) continue;
size[u] += DFS(v, u);
}
return size[u];
}
# | 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... |