# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
162202 | DifferentHeaven | Plahte (COCI17_plahte) | C++17 | 770 ms | 96528 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>
#define ii pair <int, int>
#define x first
#define y second
#define db(x) cerr << #x << " = " << x << endl;
#define _ << " _ " <<
using namespace std;
const int N = 2e5 + 7;
int m, n, gx, gy, tot, t;
int p[N], res[N], cnt[N], st[N], ft[N], ver[N];
vector <int> col[N];
bool vis[N];
vector <int> vx, vy;
map <int, int> mx, my;
vector <int> adj[N];
int sz[N];
void getsz(int v, int p){
sz[v] = 1;
st[v] = ++t;
ver[t] = v;
for(auto u : adj[v])
if(u != p){
getsz(u, v);
sz[v] += sz[u];
}
ft[v] = t;
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... |