제출 #915650

#제출 시각아이디문제언어결과실행 시간메모리
9156500xZeroBurza (COCI16_burza)C++17
컴파일 에러
0 ms0 KiB
#include "template_light.h" #define bs bitset<mx> const int mx=400; int n, k; vi adj[mx]; int dep[mx], mxd[mx]={0}; bool cmp (const bs & a, const bs & b){ F0R(i, 400)if(a[i]!=b[i])return a[i]<b[i]; return 0; } map<bs, bool, bool (*)(const bs &, const bs &)> dp(cmp); void dfs(int u, int e){ mxd[u]=dep[u]; each(i, adj[u])if(i!=e){ dep[i]=dep[u]+1; dfs(i, u); mxd[u]=max(mxd[u], mxd[i]); } } bool f(int x, int y, const bs &b){ if(x==y)return 0; if(dp.count(b))return dp[b]; bs c(0); bool ans=0; F0R(i, n)if(b[i])each(j, adj[i])if(dep[j]>dep[i] && mxd[j]>=y)c[j]=1; if(c.count()<=1)return 1; F0R(i, n)if(c[i]){ c[i]=0; ans|=f(x+1, y, c); c[i]=1; } dp[b]=ans; return ans; } int main(){ IOS; re(n, k); rep(n-1){ int a, b; re(a, b); a--;b--; adj[a].pb(b); adj[b].pb(a); } dep[0]=0; dfs(0, -1); bs b(1); if(f(0, k, b))pr("DA"); else pr("NE"); return 0; }

컴파일 시 표준 에러 (stderr) 메시지

burza.cpp:1:10: fatal error: template_light.h: No such file or directory
    1 | #include "template_light.h"
      |          ^~~~~~~~~~~~~~~~~~
compilation terminated.