# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
627209 | model_code | Digital Circuit (IOI22_circuit) | C++17 | 3077 ms | 5060 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.
// time_limit/solution-hocky-quadratic-dp.cpp
#include "circuit.h"
#include <bits/stdc++.h>
using namespace std;
const int kMod = (int) 1e9 + 2022;
struct Tree {
int n, m;
vector<int> parent, is_on;
vector<vector<int>> edge;
vector<int> memo[2];
Tree(int n_init, int m_init, vector<int> parent_init, vector<int> on_init) :
n(n_init),
m(m_init),
parent(parent_init),
is_on(on_init),
edge(n + m) {
reverse(is_on.begin(), is_on.end());
is_on.resize(n + m);
reverse(is_on.begin(), is_on.end());
for (int i = 1; i < n + m; i++) {
edge[parent[i]].push_back(i);
}
memo[0].resize(n + m, -1);
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |