# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
828928 | QwertyPi | The Xana coup (BOI21_xanadu) | C++14 | 96 ms | 18860 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("Ofast")
#define int long long
using namespace std;
const int N = 1e5 + 11;
const int INF = 1 << 30;
int dp[N][2][2];
vector<int> G[N];
int a[N];
int chmin(int& x, int y){
x = min(x, y); return x;
}
void dfs(int v, int pa = -1){
int ch = 0;
int d[2][2] = {{INF, INF}, {INF, INF}};
for(auto u : G[v]){
if(u == pa) continue; ch++; dfs(u, v);
}
for(int x = 0; x < 2; x++){
int b[2][2] = {{0, INF}, {INF, INF}};
for(auto u : G[v]){
if(u == pa) continue;
for(int z = 0; z < 2; z++){
for(int y = 0; y < 2; y++){
chmin(b[1][(z + y) % 2], b[0][z] + dp[u][x][y]);
컴파일 시 표준 에러 (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... |