上一页 1 ··· 14 15 16 17 18 19 20 21 22 ··· 33 下一页
摘要: 1 /* 2 优先队列 3 */ 4 5 #include 6 #include 7 #include 8 #include 9 #include10 #define HH 1111111111 using namespace std;12 char a[202][202];13 int visit[202][202];14 int n,m;15 int map[4][2]={{1,0},{0,1},{-1,0},{0,-1}};16 struct node17 {18 friend bool operatorn2.p;21 }22 int p;23 int... 阅读全文
posted @ 2013-11-27 19:28 芷水 阅读(224) 评论(0) 推荐(0) 编辑
摘要: PebblesTime Limit: 3000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 795Accepted Submission(s): 439Problem DescriptionYou're given an unlimited number of pebbles to distribute across an N x N game board (N drawn from [3, 15]), where each square on the board 阅读全文
posted @ 2013-11-27 19:12 芷水 阅读(274) 评论(0) 推荐(0) 编辑
摘要: 郑厂长系列故事——排兵布阵Time Limit: 10000/5000 MS (Java/Others)Memory Limit: 65535/32768 K (Java/Others)Total Submission(s): 1338Accepted Submission(s): 478Problem Description 郑厂长不是正厂长 也不是副厂长 他根本就不是厂长 事实上 他是带兵打仗的团长 一天,郑厂长带着他的军队来到了一个n*m的平原准备布阵。 根据以往的战斗经验,每个士兵可以攻击到并且只能攻击到与之曼哈顿距离为2的位置以及士兵本身所在的位置。当然,一个士兵不能站... 阅读全文
posted @ 2013-11-26 23:08 芷水 阅读(191) 评论(0) 推荐(0) 编辑
摘要: C. Dima and Saladtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputDima, Inna and Seryozha have gathered in a room. That's right, someone's got to go. To cheer Seryozha up and inspire him to have a walk, Inna decided to cook something.Dima a 阅读全文
posted @ 2013-11-26 14:53 芷水 阅读(333) 评论(0) 推荐(0) 编辑
摘要: B. Dima and To-do Listtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou helped Dima to have a great weekend, but it's time to work. Naturally, Dima, as all other men who have girlfriends, does everything wrong.Inna and Dima are now in one ro 阅读全文
posted @ 2013-11-25 22:49 芷水 阅读(334) 评论(0) 推荐(0) 编辑
摘要: Crossing RiverTime Limit:1000MSMemory Limit:10000KTotal Submissions:9887Accepted:3737DescriptionA group of N people wishes to go across a river with only one boat, which can at most carry two persons. Therefore some sort of shuttle arrangement must be arranged in order to row the boat back and forth 阅读全文
posted @ 2013-11-24 21:25 芷水 阅读(255) 评论(0) 推荐(0) 编辑
摘要: Alice's Print ServiceTime Limit: 2 Seconds Memory Limit: 65536 KBAlice is providing print service, while the pricing doesn't seem to be reasonable, so people using her print service found some tricks to save money.For example, the price when printing less than 100 pages is 20 cents per page, 阅读全文
posted @ 2013-11-24 20:16 芷水 阅读(517) 评论(0) 推荐(0) 编辑
摘要: Stripes Time Limit:1000MS Memory Limit:30000KBTotal Submit:94 Accepted:43Description Stripes is a two player game. Necessary requisites are a board and rectangular stripes in three colours: red, green and blue. All the red stripes have dimensions c x 1, green - z x 1, and blue - n x 1, where c, z an 阅读全文
posted @ 2013-11-23 16:54 芷水 阅读(483) 评论(0) 推荐(0) 编辑
摘要: 1378 - A Funny Stone GameTime limit: 3.000 secondsThe funny stone game is coming. There arenpiles of stones, numbered with0, 1, 2,...,n- 1. Two person... 阅读全文
posted @ 2013-11-22 22:21 芷水 阅读(427) 评论(0) 推荐(0) 编辑
摘要: 最长回文Time Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 6336Accepted Submission(s): 2197Problem Description给出一个只由小写英文字符a,b,c...y,z组成的字符串S,求S中最长回文串的长度.回文就是正反读都是一样的字符串,如aba, abba等Input输入有多组case,不超过120组,每组输入为一行小写英文字符a,b,c...y,z组成的字符串S两组case之间由空行隔开(该空行不用处理 阅读全文
posted @ 2013-11-22 19:46 芷水 阅读(135) 评论(0) 推荐(0) 编辑
上一页 1 ··· 14 15 16 17 18 19 20 21 22 ··· 33 下一页