摘要: 通道:http://acm.fzu.edu.cn/problem.php?pid=1977题意:单回路,有障碍点,必走点和非必走点。思路:由于有格子可以不经过,那么就导致最后一个格子无法确定,我们找到输入中最后一个无障碍的格子,那么计算的时候,以后的格子作为最后一个即可。 1 #include ... 阅读全文
posted @ 2015-07-10 19:22 mithrilhan 阅读(206) 评论(0) 推荐(0) 编辑
摘要: 通道:http://poj.org/problem?id=1739题意:左下角走到右下角路径数,单回路。做法就是我们新添2行后寻找回路就可以啦 。代码: 1 #include 2 #include 3 #include 4 5 using namespace std; 6 7... 阅读全文
posted @ 2015-07-10 17:57 mithrilhan 阅读(165) 评论(0) 推荐(0) 编辑
摘要: 通道:http://www.lydsy.com/JudgeOnline/problem.php?id=1187题意:单回路,权值,可选可不选,权值和最大。代码: 1 #include 2 #include 3 #include 4 5 using namespace std; 6... 阅读全文
posted @ 2015-07-10 17:52 mithrilhan 阅读(215) 评论(0) 推荐(0) 编辑
摘要: 通道:http://acm.hdu.edu.cn/showproblem.php?pid=1693题意:多回路路径方案数,无障碍。代码: 1 #include 2 #include 3 #include 4 5 using namespace std; 6 7 const i... 阅读全文
posted @ 2015-07-10 17:49 mithrilhan 阅读(189) 评论(0) 推荐(0) 编辑
摘要: 通道:http://acm.hdu.edu.cn/showproblem.php?pid=1964题意:单回路,权值,无阻碍。代码: 1 #include 2 #include 3 #include 4 5 using namespace std; 6 7 const int... 阅读全文
posted @ 2015-07-10 17:45 mithrilhan 阅读(156) 评论(0) 推荐(0) 编辑
摘要: 通道:http://acm.timus.ru/problem.aspx?space=1&num=1519题意:单回路,经过全部可达点,有阻碍点。代码:#include #include #include using namespace std;const int MAX_N = 13;const i... 阅读全文
posted @ 2015-07-10 17:39 mithrilhan 阅读(205) 评论(0) 推荐(0) 编辑