摘要: “.”能走,“#”不能走,“@”为起点,求所有能走到的地方。 BFS: DFS: 阅读全文
posted @ 2017-03-20 22:13 Dilthey 阅读(129) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1372 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Problem Descripti 阅读全文
posted @ 2017-03-20 20:39 Dilthey 阅读(148) 评论(0) 推荐(0) 编辑
摘要: time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output time limit per test 2 seconds time limit 阅读全文
posted @ 2017-03-19 21:02 Dilthey 阅读(173) 评论(0) 推荐(0) 编辑
摘要: 题目大意:题目很长哈,简单来说,数轴上有n个石子,第i个石头的坐标为Di,现在要从0跳到L,每次条都从一个石子跳到相邻的下一个石子。现在FJ允许你移走M个石子,问移走这M个石子后,相邻两个石子距离的最小值的最大值是多少,因为移动有很多种方法,每一种有一个最小值距离,这些最小值里面的最大值(我之所以解释最后一句,是因为我兄弟他没懂--其实不是我翻译的,嘿嘿)。 思路:在这里二分的对象当然是距离咯... 阅读全文
posted @ 2017-03-16 22:27 Dilthey 阅读(145) 评论(0) 推荐(0) 编辑
摘要: 和HDU 1789 - Doing Homework again一个套路 阅读全文
posted @ 2017-03-16 21:45 Dilthey 阅读(212) 评论(0) 推荐(0) 编辑
摘要: Time Limit: 12000/6000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 5505 Accepted Submission(s): 1320 Problem Descr 阅读全文
posted @ 2017-03-14 22:58 Dilthey 阅读(219) 评论(0) 推荐(0) 编辑
摘要: time limit per test 5 seconds memory limit per test 256 megabytes input standard input output standard output time limit per test 5 seconds time limit 阅读全文
posted @ 2017-03-13 23:08 Dilthey 阅读(308) 评论(0) 推荐(0) 编辑
摘要: time limit per test 2 seconds memory limit per test 512 megabytes input standard input output standard output time limit per test 2 seconds time limit 阅读全文
posted @ 2017-03-13 22:57 Dilthey 阅读(267) 评论(0) 推荐(0) 编辑
摘要: Description Farmer John has built a new long barn, with N (2 <= N <= 100,000) stalls. The stalls are located along a straight line at positions x1,... 阅读全文
posted @ 2017-03-13 12:32 Dilthey 阅读(174) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1789 Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Problem Descripti 阅读全文
posted @ 2017-03-09 23:21 Dilthey 阅读(284) 评论(0) 推荐(0) 编辑
摘要: Description Assume the coasting is an infinite straight line. Land is in one side of coasting, sea in the other. Each small island is a point locating 阅读全文
posted @ 2017-03-09 16:25 Dilthey 阅读(187) 评论(0) 推荐(0) 编辑
摘要: Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 13982 Accepted: 5349 Description A group of N people wishes to go across a river with only 阅读全文
posted @ 2017-03-08 22:26 Dilthey 阅读(190) 评论(0) 推荐(0) 编辑
摘要: Problem Description A number whose only prime factors are 2,3,5 or 7 is called a humble number. The sequence 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 15 阅读全文
posted @ 2017-03-06 21:55 Dilthey 阅读(132) 评论(0) 推荐(0) 编辑
摘要: time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output time limit per test 2 seconds time limit 阅读全文
posted @ 2017-03-03 23:39 Dilthey 阅读(212) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2602 Many years ago , in Teddy’s hometown there was a man who was called “Bone Collector”. This man lik 阅读全文
posted @ 2017-03-03 15:16 Dilthey 阅读(206) 评论(0) 推荐(0) 编辑
摘要: Problem Description 穿过幽谷意味着离大魔王lemon已经无限接近了!可谁能想到,yifenfei在斩杀了一些虾兵蟹将后,却再次面临命运大迷宫的考验,这是魔王lemon设下的又一个机关。要知道,不论何人,若在迷宫中被困1小时以上,则必死无疑!可怜的yifenfei为了去救MM,义无 阅读全文
posted @ 2017-03-03 12:42 Dilthey 阅读(184) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://acm.split.hdu.edu.cn/showproblem.php?pid=2955 Problem Description The aspiring Roy the Robber has seen a lot of American movies, and knows 阅读全文
posted @ 2017-03-03 08:43 Dilthey 阅读(168) 评论(0) 推荐(0) 编辑
摘要: Problem Description 在讲述DP算法的时候,一个经典的例子就是数塔问题,它是这样描述的: 有如下所示的数塔,要求从顶层走到底层,若每一步只能走到相邻的结点,则经过的结点的数字之和最大是多少? 已经告诉你了,这是个DP的题目,你能AC吗? Input 输入数据首先包括一个整数C,表示 阅读全文
posted @ 2017-03-02 00:03 Dilthey 阅读(173) 评论(0) 推荐(0) 编辑
摘要: Problem Description Given a sequence a[1],a[2],a[3]......a[n], your job is to calculate the max sum of a sub-sequence. For example, given (6,-1,5,4,-7 阅读全文
posted @ 2017-03-01 23:21 Dilthey 阅读(150) 评论(0) 推荐(0) 编辑
摘要: Largest Rectangle in a Histogram Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 17635 Accepted 阅读全文
posted @ 2017-03-01 22:28 Dilthey 阅读(181) 评论(0) 推荐(0) 编辑
摘要: Description A palindrome is a string of symbols that is equal to itself when reversed. Given an input string, not necessarily a palindrome, compute th 阅读全文
posted @ 2017-02-27 22:53 Dilthey 阅读(339) 评论(0) 推荐(0) 编辑
摘要: Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 23060 Accepted Submission(s): 9172 Problem Descr 阅读全文
posted @ 2017-02-26 20:32 Dilthey 阅读(205) 评论(0) 推荐(0) 编辑
摘要: 刘汝佳上的题目。 刘汝佳书上的做法明显更加精简……不过刚学STL……老老实实的把四种行为做出来比较靠谱…… 阅读全文
posted @ 2017-02-23 20:55 Dilthey 阅读(191) 评论(0) 推荐(0) 编辑
摘要: Description A friend of you has just bought a new computer. Until now, the most powerful computer he ever used has been a pocket calculator. Now, look 阅读全文
posted @ 2017-02-20 19:38 Dilthey 阅读(167) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1002 Problem DescriptionI have a very simple problem for you. Given two integers A and B, your job is t 阅读全文
posted @ 2017-02-20 19:38 Dilthey 阅读(141) 评论(0) 推荐(0) 编辑