# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1047807 | MercubytheFirst | Split the Attractions (IOI19_split) | C++14 | 1 ms | 600 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>
#include "split.h"
using namespace std;
using pii = pair<int, int>;
vector<int> tin, low, root, val;
int timer;
vector<vector<pii> > g;
vector<vector<int> > cg, components(1);
int comp_cnt = 0;
vector<bool> vis;
vector<bool> is_bridge;
vector<int> sub;
pair<int, int> sz[3];
int cnt[3];
int ansv = -1, ansp = -1;
int sub_dfs(int v, int p) {
sub[v] = val[v];
for(int to : cg[v]) {
if(to != p) {
sub[v] += sub_dfs(to, v);
}
}
return sub[v];
}
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... |