# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1102090 | _8_8_ | Dango Maker (JOI18_dango_maker) | C++17 | 44 ms | 262144 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>
using namespace std;
typedef long long ll;
const int N = 3e3 + 12, MOD = 998244353;
char a[N][N];
int n, m, res = 0, res1 = 0, v[N][N], it = 1, h[N][N], dp[N][N];
vector<int> g[N * N];
void add(int x, int y) {
g[x].push_back(y);
g[y].push_back(x);
}
bool vis[N];
void dfs(int v, int pr = -1) {
vis[v] = 1;
dp[v][1] = 1;
for(int to:g[v]) {
if(to == pr || vis[to]) continue;
dfs(to, v);
dp[v][0] += max(dp[to][0], dp[to][1]);
dp[v][1] += dp[to][0];
}
}
void test() {
cin >> n >> m;
for(int i = 1; i <= n; i++) {
for(int j = 1; j <= m; j++) {
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |