# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
848019 | LeonaRaging | Cats or Dogs (JOI18_catdog) | C++14 | 484 ms | 28280 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 "catdog.h"
#include<bits/stdc++.h>
using namespace std;
#define pb push_back
const int maxn = 1e5 + 4;
const int INF = 1e9;
int n, sz[maxn], R[maxn], B[maxn], col[maxn], par[maxn], id[maxn];
int chain[maxn], head[maxn], from[maxn], to[maxn], tin[maxn];
vector<int> adj[maxn];
struct Node {
int a[2][2];
Node() {
for (int i = 0; i < 2; i++)
for (int j = 0; j < 2; j++)
a[i][j] = INF;
}
};
struct seg_tree {
vector<Node> t;
seg_tree() {
t.resize(4 * maxn);
}
Node merge(Node L, Node R) {
Node res;
for (int i = 0; i < 2; i++)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |