# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
662108 | fatemetmhr | Homework (CEOI22_homework) | C++17 | 193 ms | 149704 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
// heiy ... ye rooze jadid ...
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define all(x) x.begin(), x.end()
#define pb push_back
#define fi first
#define se second
const int maxn5 = 2e6 + 10;
int l[maxn5], r[maxn5], sz[maxn5];
vector <int> adj[maxn5], av;
bool ty[maxn5];
void dfs(int v){
if(adj[v].empty()){
l[v] = r[v] = 1;
sz[v] = 1;
return;
}
int u = adj[v][0], w = adj[v][1];
dfs(u); dfs(w);
sz[v] = sz[u] + sz[w];
if(ty[v]){
int tmpl = sz[u] - r[u] + 1, tmpr = sz[u] - (l[u] - 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... |