永夜初晗凝碧天

本博客现已全部转移到新地址,欲获取更多精彩文章,请访问http://acshiryu.github.io/

导航

2011年7月17日 #

HDOJ 1754 I Hate It 解题报告

摘要: I Hate ItTime Limit: 9000/3000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 8782Accepted Submission(s): 3239Problem Description很多学校流行一种比较的习惯。老师们很喜欢询问,从某某到某某当中,分数最高的是多少。这让很多学生很反感。不管你喜不喜欢,现在需要你做的是,就是按照老师的要求,写一个程序,模拟老师的询问。当然,老师有时候需要更新某位同学的成绩。Input本题目包含多组测试,请处理到文件结束。在每个测 阅读全文

posted @ 2011-07-17 20:56 ACShiryu 阅读(384) 评论(0) 推荐(0) 编辑

USACO 2.3.3 Zero Sum 解题报告

摘要: Zero SumConsider the sequence of digits from 1 through N (where N=9) in increasing order: 1 2 3 ... N.Now insert either a `+' for addition or a `-' for subtraction or a ` ' [blank] to run the digits together between each pair of digits (not in front of the first digit). Calculate the res 阅读全文

posted @ 2011-07-17 11:37 ACShiryu 阅读(453) 评论(0) 推荐(0) 编辑

USACO 2.3.2 Cow Pedigrees 解题报告

摘要: 分类:DP作者:ACShiryu时间:2011-7-17Cow PedigreesSilviu Ganceanu -- 2003Farmer John is considering purchasing a new herd of cows. In this new herd, each mother cow gives birth to two children. The relationships among the cows can easily be represented by one or more binary trees with a total of N (3 <= N 阅读全文

posted @ 2011-07-17 11:24 ACShiryu 阅读(515) 评论(0) 推荐(0) 编辑