dfs
箱@子
这个作者很懒,什么都没留下…
展开
-
2020暑假牛客多校第九场 K The Flee Plan of Groundhog (DFS)
Groundhog was especially careful after the outbreak,so he put on his mask in the1^{st}1stbedroom early,and then walked on the way to the{n^{th}}nthdormitory to play with Orange.There are{n}ndormitories in ZLZX, which are connected by{n-1}n−1corrid...原创 2020-08-09 12:01:38 · 203 阅读 · 0 评论 -
树形dp模板题 洛谷P2015 二叉苹果树
输入样例#1:复制 5 2 1 3 1 1 4 10 2 3 20 3 5 20 输出样例#1:复制 21 链式前向星存图 在q范围内计算左右儿子的苹果和 #include<bits/stdc++.h> using namespace std; const int maxn = 105; int dp[maxn][maxn]; int head[maxn]; ...原创 2019-07-09 11:41:10 · 155 阅读 · 0 评论 -
HUD2612 双路bfs
Find a way Time Limit: 3000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 23878Accepted Submission(s): 7791 Pass a year learning in Hangzhou, yifenfei ar...原创 2019-07-05 10:50:55 · 140 阅读 · 0 评论