# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
781865 | Andrey | Cat Exercise (JOI23_ho_t4) | C++14 | 294 ms | 65136 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 <bits/stdc++.h>
using namespace std;
vector<long long> h(200001);
vector<long long> haha[200001];
vector<long long> dsu(200001);
vector<long long> dep(200001);
long long bruh[200001][19];
void dfs(long long a, long long t, long long d) {
bruh[a][0] = t;
dep[a] = d;
for(long long v: haha[a]) {
if(v != t) {
dfs(v,a,d+1);
}
}
}
long long check(long long a) {
long long c = a,d,e;
while(dsu[c] != c) {
c = dsu[c];
}
d = a;
while(d != dsu[d]) {
e = dsu[d];
dsu[d] = c;
d = e;
}
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |