# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
405063 | ly20 | Connecting Supertrees (IOI20_supertrees) | C++17 | 0 ms | 0 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 "supertrees.h"
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1123;
int comp[MAXN];
vector <int> grafo[MAXN];
int marc[MAXN];
int cmp;
//vector <int> grafo2[MAXN];
void dfs(int v) {
marc[v] = 1;
comp[v] = cmp;
for(int i = 0; i < grafo[v].size(); i++) {
int viz = grafo[v][i];
if(marc[viz] == 1) continue;
dfs(viz);
}
}
int resp[MAXN][MAXN];
int rep[MAXN];
int cic[MAXN][MAXN];
int rep[MAXN];
int cm2[MAXN], cmp2;
int marc2[MAXN];
vector <int> ln[MAXN];
vector <vector <int> > answer;
//vector <int> temp;
void dfs2(int v) {
marc2[v] = 1;
cm2[v] = cmp2;