摘要: POJ 1416 dfs递归枚举+记录路径Shredding CompanyTime Limit:1000MSMemory Limit:10000KTotal Submissions:4456Accepted:2555DescriptionYou have just been put in char... 阅读全文
posted @ 2015-03-13 19:24 __560 阅读(291) 评论(0) 推荐(0) 编辑
摘要: bfs算法模版写过很多bfs题,每次写bfs代码习惯都略有不同,有些糟糕的代码习惯影响了解题速度下面这份简单的三维bfs可以算是写得比较不错的一份了,以后按这种习惯写,虽然没有写回溯路径,但回溯路径很简单,只要加个fa数组就行了,所以就不加在模版上了//bfs模版int X,Y,Z;char ch[... 阅读全文
posted @ 2015-03-13 14:43 __560 阅读(408) 评论(0) 推荐(0) 编辑
摘要: POJ 2531 dfs递归枚举Network SaboteurTime Limit:2000MSMemory Limit:65536KTotal Submissions:9580Accepted:4560DescriptionA university network is composed of ... 阅读全文
posted @ 2015-03-13 14:33 __560 阅读(335) 评论(0) 推荐(0) 编辑
摘要: POJ 1326 对数位的bfsPrime PathTime Limit:1000MSMemory Limit:65536KTotal Submissions:12480Accepted:7069DescriptionThe ministers of the cabinet were quite u... 阅读全文
posted @ 2015-03-13 12:01 __560 阅读(209) 评论(0) 推荐(0) 编辑
摘要: POJ 1426 数的bfs,打表Find The MultipleTime Limit:1000MSMemory Limit:10000KTotal Submissions:19409Accepted:7868Special JudgeDescriptionGiven a positive int... 阅读全文
posted @ 2015-03-13 10:53 __560 阅读(385) 评论(0) 推荐(0) 编辑
摘要: POJ 3278 对数轴进行一维bfsCatch That CowTime Limit:2000MSMemory Limit:65536KTotal Submissions:52161Accepted:16355DescriptionFarmer John has been informed of... 阅读全文
posted @ 2015-03-13 10:03 __560 阅读(314) 评论(0) 推荐(0) 编辑
摘要: POJ 2251 bfsDungeon MasterTime Limit:1000MSMemory Limit:65536KTotal Submissions:18245Accepted:7075DescriptionYou are trapped in a 3D dungeon and need ... 阅读全文
posted @ 2015-03-13 00:18 __560 阅读(264) 评论(0) 推荐(0) 编辑