排序:
默认
按更新时间
按访问量

A计划 HDU - 2102 (bfs)

A计划  HDU - 2102  可怜的公主在一次次被魔王掳走一次次被骑士们救回来之后,而今,不幸的她再一次面临生命的考验。魔王已经发出消息说将在T时刻吃掉公主,因为他听信谣言说吃公主的肉也能长生不老。年迈的国王正是心急如焚,告招天下勇士来拯救公主。不过公主早已习以为常,她深信智勇的骑士LJ肯...

2018-10-27 21:49:27

阅读数:46

评论数:0

哈密顿绕行世界问题 HDU - 2181(dfs)

哈密顿绕行世界问题  HDU - 2181 一个规则的实心十二面体,它的 20个顶点标出世界著名的20个城市,你从一个城市出发经过每个城市刚好一次后回到出发的城市。  Input 前20行的第i行有3个数,表示与第i个城市相邻的3个城市.第20行以后每行有1个数m,m&lt...

2018-10-27 10:40:34

阅读数:6

评论数:0

Fire Game FZU - 2150 (bfs)

Fire Game  FZU - 2150  Fat brother and Maze are playing a kind of special (hentai) game on an N*M board (N rows, M columns). At the beginning, each...

2018-10-23 11:20:10

阅读数:9

评论数:0

Fire! UVA - 11624 (bfs)

Fire!  UVA - 11624  题目链接https://cn.vjudge.net/problem/UVA-11624   题意:J是人,只有一个,F是火可以有多个,#是墙,‘.’是人和火都能走的地方,问人走出边界需要几步 思路:bfs(好久不写搜索了,手好生。。。),之前被卡住...

2018-10-22 22:42:07

阅读数:10

评论数:0

水陆距离 HihoCoder - 1478(bfs+思维)

水陆距离                HihoCoder - 1478 给定一个N x M的01矩阵,其中1表示陆地,0表示水域。对于每一个位置,求出它距离最近的水域的距离是多少。   矩阵中每个位置与它上下左右相邻的格子距离为1。 Input 第一行包含两个整数,N和M。 以下N行每...

2018-07-29 19:10:27

阅读数:30

评论数:0

Borg Maze  POJ - 3026(bfs+最小生成树)

Borg Maze  POJ - 3026 The Borg is an immensely powerful race of enhanced humanoids from the delta quadrant of the galaxy. The Borg collective is th...

2018-07-19 15:00:51

阅读数:27

评论数:0

Fire Net ZOJ - 1002 (dfs)

 Fire Net ZOJ - 1002 Suppose that we have a square city with straight streets. A map of a city is a square board with n rows and n columns, each repr...

2018-06-09 21:40:08

阅读数:26

评论数:0

Rescue ZOJ - 1649 (bfs 优先队列)

Rescue ZOJ - 1649 Angel was caught by the MOLIGPY! He was put in prison by Moligpy. The prison is described as a N * M (N, M <= 200) matri...

2018-06-09 08:53:53

阅读数:33

评论数:0

Find a way HDU - 2612 (bfs)

 Find a way HDU - 2612 Pass a year learning in Hangzhou, yifenfei arrival hometown Ningbo at finally. Leave Ningbo one year, yifenfei have many peopl...

2018-06-08 08:50:51

阅读数:33

评论数:0

Knight Moves POJ - 1915 (bfs入门)

 Knight Moves POJ - 1915 Background Mr Somurolov, fabulous chess-gamer indeed, asserts that no one else but him can move knights from one position to...

2018-06-03 21:32:41

阅读数:27

评论数:0

Prime Ring Problem HDU - 1016 (dfs、(素数筛模板))

Prime Ring Problem HDU - 1016 A ring is compose of n circles as shown in diagram. Put natural number 1, 2, ..., n into each circle separately, and th...

2018-05-24 09:28:42

阅读数:22

评论数:0

dfs最短路模板

#include<iostream> #include<cstdio> #include<cstring> #include<algorithm...

2018-05-23 23:07:52

阅读数:61

评论数:0

N皇后问题 HDU - 2553(dfs)

N皇后问题 HDU - 2553在N*N的方格棋盘放置了N个皇后,使得它们不相互攻击(即任意2个皇后不允许处在同一排,同一列,也不允许处在与棋盘边框成45角的斜线上。 你的任务是,对于给定的N,求出有多少种合法的放置方法。 Input共有若干行,每行一个正整数N≤10,表示棋盘和皇后的数量;如果N...

2018-05-23 22:15:14

阅读数:17

评论数:0

Lotto HDU - 1342(dfs)

    Lotto HDU - 1342In a Lotto I have ever played, one has to select 6 numbers from the set {1,2,...,49}. A popular strategy to play Lotto - although...

2018-05-23 10:16:37

阅读数:23

评论数:0

Ancient Go

Ancient GoYu Zhou likes to play Go with Su Lu. From the historical research, we found that there are much difference on the rules between ancient go ...

2018-05-02 22:25:14

阅读数:31

评论数:0

Sudoku

SudokuYi Sima was one of the best counselors of Cao Cao. He likes to play a funny game himself. It looks like the modern Sudoku, but smaller. Actuall...

2018-05-02 21:34:19

阅读数:43

评论数:0

A Knight's Journey (dfs)

B - A Knight's JourneyBackground The knight is getting bored of seeing the same black and white squares again and again and has decided to make a jou...

2018-03-19 21:48:24

阅读数:34

评论数:0

D - Sticks POJ - 1011 (深搜 剪枝)

D - Sticks POJ - 1011 George took sticks of the same length and cut them randomly until all parts became at most 50 units long. Now he wants to retur...

2018-03-14 22:12:03

阅读数:38

评论数:0

滑雪 POJ - 1088 (记忆化搜索)

滑雪  POJ - 1088  Michael喜欢滑雪百这并不奇怪, 因为滑雪的确很刺激。可是为了获得速度,滑的区域必须向下倾斜,而且当你滑到坡底,你不得不再次走上坡或者等待升降机来载你。Michael想知道载一个区域中最长底滑坡。区域由一个二维数组给出。数组的每个数字代表点的...

2017-11-29 20:53:57

阅读数:126

评论数:0

Prime Ring Problem HDU - 1016 (深搜)

Prime Ring Problem  HDU - 1016  A ring is compose of n circles as shown in diagram. Put natural number 1, 2, ..., n into each circle separa...

2017-11-14 18:29:52

阅读数:83

评论数:0

提示
确定要删除当前文章?
取消 删除
关闭
关闭