专题二 搜索进阶
坏坏的感觉
这个作者很懒,什么都没留下…
展开
-
专题训练二 搜索进阶 HDU - 2102 A计划
HDU - 2102 A计划Problem Description可怜的公主在一次次被魔王掳走一次次被骑士们救回来之后,而今,不幸的她再一次面临生命的考验。魔王已经发出消息说将在T时刻吃掉公主,因为他听信谣言说吃公主的肉也能长生不老。年迈的国王正是心急如焚,告招天下勇士来拯救公主。不过公主早已习以为常,她深信智勇的骑士LJ肯定能将她救出。现据密探所报,公主被关在一个两层的迷宫里,迷宫的入口是S(0,0,0),公主的位置用P表示,时空传输机用#表示,墙用*表示,平地用.表示。骑士们一进入时空传输机就会被原创 2020-12-14 23:41:15 · 55 阅读 · 0 评论 -
专题训练二 搜索进阶 HDU - 1067 Gap (BFS + map映射)
HDU - 1067 GapProblem DescriptionLet’s play a card game called Gap.You have 28 cards labeled with two-digit numbers. The first digit (from 1 to 4) represents the suit of the card, and the second digit (from 1 to 7) represents the value of the card.Firs原创 2020-12-14 08:13:45 · 128 阅读 · 0 评论 -
HDU - 1560 (IDA*, DFS + 回溯)
HDU - 1560 DNA sequenceProblem DescriptionThe twenty-first century is a biology-technology developing century. We know that a gene is made of DNA. The nucleotide bases from which DNA is built are A(adenine), C(cytosine), G(guanine), and T(thymine). Findi原创 2020-12-13 22:11:37 · 136 阅读 · 0 评论 -
专题训练二 搜索进阶 HDU - 3533 Escape (BFS,A*(曼哈顿距离))
HDU - 3533 EscapeProblem DescriptionThe students of the HEU are maneuvering for their military training.The red army and the blue army are at war today. The blue army finds that Little A is the spy of the red army, so Little A has to escape from the hea原创 2020-12-13 19:44:36 · 104 阅读 · 0 评论 -
专题训练二 搜索进阶 HDU - 2181 哈密顿绕行世界问题 (DFS 回溯法)
HDU - 2181 哈密顿绕行世界问题 (DFS 回溯法)Problem Description一个规则的实心十二面体,它的 20个顶点标出世界著名的20个城市,你从一个城市出发经过每个城市刚好一次后回到出发的城市。Input前20行的第i行有3个数,表示与第i个城市相邻的3个城市.第20行以后每行有1个数m,m<=20,m>=1.m=0退出.Output输出从第m个城市出发经过每个城市1次又回到m的所有路线,如有多条路线,按字典序输出,每行1条路线.每行首先输出是第几条路线.然后原创 2020-12-12 16:47:49 · 116 阅读 · 0 评论 -
专题训练二 搜索进阶 HDU - 3085 Nightmare Ⅱ (双向BFS + 曼哈顿距离)
HDU - 3085 Nightmare Ⅱ (双向BFS + 曼哈顿距离)Problem DescriptionLast night, little erriyue had a horrible nightmare. He dreamed that he and his girl friend were trapped in a big maze separately. More terribly, there are two ghosts in the maze. They will kill th原创 2020-12-12 16:04:56 · 111 阅读 · 0 评论