# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1134017 | heeheeheehaaw | The Xana coup (BOI21_xanadu) | C++20 | 87 ms | 26440 KiB |
#include <bits/stdc++.h>
using namespace std;
int dp[100005][2][2];
int v[100005];
vector<int> adj[100005];
const int INF = 1e9;
void dfs(int nod, int parent)
{
bool ok = false;
for(auto it : adj[nod])
{
if(it != parent)
{
ok = true;
dfs(it, nod);
}
}
if(ok == false)
{
if(v[nod] == 1)
{
dp[nod][0][0] = INF;
dp[nod][0][1] = 0;
dp[nod][1][0] = 1;
dp[nod][1][1] = INF;
}
# | 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... |