# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
542619 | alvingogo | Unique Cities (JOI19_ho_t5) | C++14 | 449 ms | 39600 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>
#pragma GCC optimize("Ofast")
#define AquA cin.tie(0);ios_base::sync_with_stdio(0);
#define fs first
#define sc second
#define cd complex<double>
#define p_q priority_queue
using namespace std;
struct no{
vector<int> ch;
int co;
int dis;
int hh=0;
int ans=0;
};
vector<no> v;
vector<int> cnt;
int cz=0;
int t=0;
void dfs1(int r,int f,int dis){
if(t==-1 || dis>v[t].dis){
t=r;
}
v[r].dis=dis;
for(auto y:v[r].ch){
if(y!=f){
dfs1(y,r,dis+1);
}
}
# | 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... |