人生列车

follow on!success!

导航

2014年7月29日 #

关于输入一组数据求最小的问题

摘要: 问题链接:http://acm.csu.edu.cn/OnlineJudge/problem.php?id=1350http://acm.csu.edu.cn/OnlineJudge/problem.php?id=1408两个问题,自己第一个代码是没有敲出来的,第二个代码虽然是搞定了,但是在处理是分... 阅读全文

posted @ 2014-07-29 15:14 tianxia2s 阅读(223) 评论(0) 推荐(0) 编辑

排兵布阵之线段树

摘要: 敌兵布阵Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 42138Accepted Submission(s): 17826Problem Desc... 阅读全文

posted @ 2014-07-29 10:45 tianxia2s 阅读(211) 评论(1) 推荐(0) 编辑

2014年7月28日 #

Codeforces 237C

摘要: 题目:DescriptionYou've decided to carry out a survey in the theory of prime numbers. Let us remind you that a prime number is a positive integer that ha... 阅读全文

posted @ 2014-07-28 17:27 tianxia2s 阅读(196) 评论(2) 推荐(0) 编辑

状态压缩DP

摘要: status{x1,x2,x3,x4,………xn-1,xn}表示每只鱼是否还活着的状态 xi=1表示第i条鱼还活着 xi=0表示第i条鱼已经被吃掉了 dp(status)表示形成status这种状态的概率 那么刚开始的时候(第一天),所有的鱼都活着。 那么dp({1,1,1,1….,1,1,1})=... 阅读全文

posted @ 2014-07-28 17:00 tianxia2s 阅读(163) 评论(0) 推荐(0) 编辑

KMP算法类习题——字符串匹配

摘要: DescriptionFor each prefix with length P of a given string S,ifS[i]=S[i+P] for i in [0..SIZE(S)-p-1],then the prefix is a “period” of S. We want to al... 阅读全文

posted @ 2014-07-28 13:13 tianxia2s 阅读(332) 评论(0) 推荐(0) 编辑