摘要: Problem DescriptionFarmer John has been informed of the location of a fugitive cow and wants to catch her immediately. He starts at a point N (0 ≤ N ≤ 阅读全文
posted @ 2019-02-22 20:16 鹤花之歌 阅读(150) 评论(0) 推荐(0) 编辑
摘要: cf/gym-101755H Safe Path 【BFS】 http://codeforces.com/gym/101755/problem/H HDU-1045 Fire Net https://vjudge.net/contest/283487#problem/F 阅读全文
posted @ 2019-02-22 19:58 鹤花之歌 阅读(186) 评论(0) 推荐(0) 编辑
摘要: DescriptionMahmoud and Ehab are on the third stage of their adventures now. As you know, Dr. Evil likes sets. This time he won’t show them any set fro 阅读全文
posted @ 2019-02-22 19:52 鹤花之歌 阅读(179) 评论(0) 推荐(0) 编辑
摘要: Description 在讲述DP算法的时候,一个经典的例子就是数塔问题,它是这样描述的: 有如下所示的数塔,要求从顶层走到底层,若每一步只能走到相邻的结点,则经过的结点的数字之和最大是多少? 已经告诉你了,这是个DP的题目,你能AC吗? Input 输入数据首先包括一个整数C,表示测试实例的个数, 阅读全文
posted @ 2019-02-22 19:15 鹤花之歌 阅读(156) 评论(0) 推荐(0) 编辑
摘要: Problem Description“今年暑假不AC?”“是的。”“那你干什么呢?”“看世界杯呀,笨蛋!”“@#$%^&*%...” 确实如此,世界杯来了,球迷的节日也来了,估计很多ACMer也会抛开电脑,奔向电视了。作为球迷,一定想看尽量多的完整的比赛,当然,作为新时代的好青年,你一定还会看一些 阅读全文
posted @ 2019-02-22 19:01 鹤花之歌 阅读(131) 评论(0) 推荐(0) 编辑
摘要: Vanya walks late at night along a straight street of length l, lit by n lanterns. Consider the coordinate system with the beginning of the street corr 阅读全文
posted @ 2019-02-22 18:45 鹤花之歌 阅读(403) 评论(0) 推荐(0) 编辑
摘要: Description In 1742, Christian Goldbach, a German amateur mathematician, sent a letter to Leonhard Euler in which he made the following conjecture: Ev 阅读全文
posted @ 2019-02-22 18:34 鹤花之歌 阅读(236) 评论(0) 推荐(0) 编辑
摘要: You are given a string ss, consisting of nn lowercase Latin letters. A substring of string ss is a continuous segment of letters from ss. For example, 阅读全文
posted @ 2019-02-22 17:08 鹤花之歌 阅读(177) 评论(0) 推荐(0) 编辑
摘要: 题意:和韩信点兵差不多,不过这个要求更高一些。 阅读全文
posted @ 2019-02-22 17:03 鹤花之歌 阅读(126) 评论(0) 推荐(0) 编辑
摘要: 很迷的map,虽然很基础不过很迷 1 #include 2 using namespace std; 3 int main(){ 4 int N;cin>>N; 5 while(N--){ 6 int n;cin>>n; 7 map >mapp; 8 while(n--){ 9 string... 阅读全文
posted @ 2019-02-22 14:03 鹤花之歌 阅读(245) 评论(0) 推荐(0) 编辑
摘要: emmm还是不明白输入输出流是什么 阅读全文
posted @ 2019-02-22 14:01 鹤花之歌 阅读(91) 评论(0) 推荐(0) 编辑
摘要: 题意:第一行输入数字个数。 第二行输入 一串数字。 要求找出大于1/2数量的数。 Tips:将这串数字从小到大依次排序,中间的数 一定是数量超过1/2的数。(蜜汁数学问题) 阅读全文
posted @ 2019-02-22 13:58 鹤花之歌 阅读(79) 评论(0) 推荐(0) 编辑
摘要: 题意:问 给出的一串括号,有几对是匹配括号。 阅读全文
posted @ 2019-02-22 11:06 鹤花之歌 阅读(85) 评论(0) 推荐(0) 编辑
摘要: 题意:只有一个人是能够赢所有人的。 阅读全文
posted @ 2019-02-22 10:45 鹤花之歌 阅读(132) 评论(0) 推荐(0) 编辑