摘要: 题目:Problem Description经过锦囊相助,海东集团终于度过了危机,从此,HDU的发展就一直顺风顺水,到了2050年,集团已经相当规模了,据说进入了钱江肉丝经济开发区500强。这时候,XHD夫妇也退居了二线,并在风景秀美的诸暨市浬浦镇陶姚村买了个房子,开始安度晚年了。这样住了一段时间,徐总对当地的交通还是不太了解。有时很郁闷,想去一个地方又不知道应该乘什么公交车,在什么地方转车,在什么地方下车(其实徐总自己有车,却一定要与民同乐,这就是徐总的性格)。徐总经常会问蹩脚的英文问路:“Can you help me?”。看着他那迷茫而又无助的眼神,热心的你能帮帮他吗?请帮助他用最短的时 阅读全文
posted @ 2013-09-06 20:47 lysr__tlp 阅读(255) 评论(0) 推荐(0) 编辑
摘要: 题目 :Problem Description还记得Gardon给小希布置的那个作业么?(上次比赛的1005)其实小希已经找回了原来的那张数表,现在她想确认一下她的答案是否正确,但是整个的答案是很庞大的表,小希只想让你把答案中最大的M个数告诉她就可以了。给定一个包含N(N 2 #include 3 #include 4 using namespace std; 5 6 7 int main(){ 8 int n,m,x,A[3005],hash[10005],flag,i,j; 9 while( cin >>n >>m ){10 memset(hash,0,... 阅读全文
posted @ 2013-08-29 12:48 lysr__tlp 阅读(237) 评论(0) 推荐(0) 编辑
摘要: 题目:Problem DescriptionAfter Mr. B arrived in Warsaw, he was shocked by the skyscrapers and took several photos. But now when he looks at these photos, he finds in surprise that he isn't able to point out even the number of buildings in it. So he decides to work it out as follows:- divide the pho 阅读全文
posted @ 2013-08-26 17:47 lysr__tlp 阅读(246) 评论(0) 推荐(0) 编辑
摘要: 题目 :Problem DescriptionDandelion's uncle is a boss of a factory. As the spring festival is coming , he wants to distribute rewards to his workers. Now he has a trouble about how to distribute the rewards.The workers will compare their rewards ,and some one may have demands of the distributing of 阅读全文
posted @ 2013-08-24 11:22 lysr__tlp 阅读(178) 评论(0) 推荐(0) 编辑
摘要: 题目:Problem DescriptionBean-eating is an interesting game, everyone owns an M*N matrix, which is filled with different qualities beans. Meantime, there is only one bean in any 1*1 grid. Now you want to eat the beans and collect the qualities, but everyone must obey by the following rules: if you eat 阅读全文
posted @ 2013-08-23 11:21 lysr__tlp 阅读(164) 评论(0) 推荐(0) 编辑
摘要: 题 目 :Problem DescriptionLittle E is doing geometry works. After drawing a lot of points on a plane, he want to enumerate all the triangles which the vertexes are three of the points to find out the one with minimum perimeter. Your task is to implement his work.InputThe input contains several test ca 阅读全文
posted @ 2013-08-22 10:26 lysr__tlp 阅读(245) 评论(0) 推荐(0) 编辑
摘要: 题 目 :Problem DescriptionGiven n elements, which have two properties, say Property A and Property B. For convenience, we use two integers Aiand Bito measure the two properties.Your task is, to partition the element into two sets, say Set A and Set B , which minimizes the value of max(x∈Set A){Ax}+max 阅读全文
posted @ 2013-08-22 10:02 lysr__tlp 阅读(237) 评论(0) 推荐(0) 编辑
摘要: 参考:http://blog.csdn.net/dgq8211/article/details/7733275现在 还不是太明白。代码: 1 #include 2 #include 3 #include 4 #include 5 6 using namespace std; 7 8 struct food 9 {10 int price,value;11 };12 13 vector Q[15];14 int dp[15][10005];15 16 int main( ) {17 18 int n,k,Sum,a,b,c;19 food t;20 whil... 阅读全文
posted @ 2013-08-20 17:32 lysr__tlp 阅读(146) 评论(0) 推荐(0) 编辑
摘要: 题目 :Problem DescriptionACboy has N courses this term, and he plans to spend at most M days on study.Of course,the profit he will gain from different course depending on the days he spend on it.How to arrange the M days for the N courses to maximize the profit?InputThe input consists of multiple data 阅读全文
posted @ 2013-08-20 14:31 lysr__tlp 阅读(137) 评论(0) 推荐(0) 编辑
摘要: 题目 :Problem DescriptionNew semester is coming, and DuoDuo has to go to school tomorrow. She decides to have fun tonight and will be very busy after tonight. She like watch cartoon very much. So she wants her uncle to buy some movies and watch with her tonight. Her grandfather gave them L minutes to 阅读全文
posted @ 2013-08-19 19:24 lysr__tlp 阅读(184) 评论(0) 推荐(0) 编辑