# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1163952 | iah | Werewolf (IOI18_werewolf) | C++20 | 490 ms | 82684 KiB |
#include "werewolf.h"
#include <bits/stdc++.h>
using namespace std;
#define NAME ""
#define ll long long
#define pii pair < int , int >
#define fi first
#define se second
#define FOR(i, a, b) for (int i = (a), _b = (b); i <= _b; i ++)
#define FORD(i, a, b) for (int i = (a), _b = (b); i >= _b; i --)
#define REP(i, n) for (int i = 0, _n = (n); i < _n; i ++)
#define bit(x, i) (((x) >> (i)) & 1ll)
#define mask(x) (1ll << (x))
#define mem(f, x) memset(f, x, sizeof(f))
#define sz(x) (int32_t) (x.size())
const int nmax = 2e5;
int timer = 0, in[2][nmax + 4], out[2][nmax + 4], top[2][nmax + 4], rev[nmax + 4];
vector < int > g[nmax + 4], adj[nmax + 4], ql[nmax + 4], qr[nmax + 4], op[nmax + 4], cl[nmax + 4];
struct DSU {
int par[nmax + 4];
void init(int n) {
iota(par, par + n, 0);
}
int find_par(int i) {
return (par[i] == i ? i : par[i] = find_par(par[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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |