![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
DFS
文章平均质量分 63
Unin88
这个作者很懒,什么都没留下…
展开
-
POJ 1753 Flip Game
http://poj.org/problem?id=1753 1.反转ji sh原创 2014-11-16 13:15:02 · 325 阅读 · 0 评论 -
UVA 572 Oil Deposits
DFS求连通块 #include #include #include #include using namespace std; int m,n,idx[110][110]; char pic[110][110]; bool Isgood(int r, int c){ if(r = m || c = n) return false; return t原创 2014-10-18 14:13:27 · 409 阅读 · 0 评论 -
B - The Pilots Brothers' refrigerator
DFS且记录路径 #include #include #include #include using namespace std; bool handle[5][5] = {false}; int flag, step,r[20],c[20]; bool IsGood(){ for(int i=1; i<=4; i++) for(int j=1;原创 2014-11-16 14:21:18 · 436 阅读 · 0 评论 -
POJ 1111 Image Perimeters
http://poj.org/problem?id=1111原创 2014-11-17 20:51:00 · 353 阅读 · 0 评论 -
HDU 1016 Prime Ring Problem
http://acm.hdu.edu.cn/showproblem.php?pid=1016原创 2014-11-17 19:45:11 · 323 阅读 · 0 评论 -
C. Guess Your Way Out!
#include #include #include #include #include using namespace std; long long h,n; long long DFS(long long p, long long n, int sign){ if(p == h) return 0; if(!sign && n > (1LL << (h原创 2015-01-27 12:41:17 · 438 阅读 · 0 评论 -
B. Mr. Kitayuta's Colorful Graph
看数据范围觉得可以暴力搜索,高效的我也不会= = #include #include #include #include #include using namespace std; int n,m,q; int u,v,c; int vis[110]; vector > vt[110]; void Init(){ for(int i=1; i<=m; i++)原创 2015-01-19 18:35:59 · 407 阅读 · 0 评论