随笔分类 - 动态规划——普通dp
摘要:Problem M. Walking PlanTime Limit: 5000/2500 MS (Java/Others) Memory Limit: 524288/524288 K (Java/Others)Total Submission(s): 897 Accepted Submission(
阅读全文
摘要:子序列的定义:对于一个序列a=a1 1 ,a2 2 ,......an n 。则非空序列a'=ap1 p1 ,ap2 p2 ......apm pm 为a的一个子序列,其中1<=p1<p2<.....<pm<=n。 例如4,14,2,3和14,1,2,3都为4,13,14,1,2,3的子序列。对于给
阅读全文
摘要:起起落落 尚未提交 尚未通过 时间限制:1000ms 内存限制:256MB 0.00% 提交人数:12 通过人数:0 起起落落 尚未提交 尚未通过 时间限制:1000ms 内存限制:256MB 起起落落 尚未提交 尚未通过 时间限制:1000ms 内存限制:256MB 0.00% 提交人数:12 通
阅读全文
摘要:Charlie's ChangeTime Limit: 1000MS Memory Limit: 30000KTotal Submissions: 4505 Accepted: 1420Description Charlie is a driver of Advanced Cargo Movemen
阅读全文
摘要:Little Sub loves playing the game Flip Me Please. In the game, lights, numbered from 1 to , are connected separately to switches. The lights may be ei
阅读全文
摘要:2072. Kirill the Gardener 3Time limit: 2.0 secondMemory limit: 64 MBKirill the gardener has got a new task. He has to water the flowers growing on the
阅读全文
摘要:Warm sunshine, cool wind and a fine day, while the girl watching is pursuing in chaos. Rikka reached out her hand and got the garland on her head, fin
阅读全文
摘要:题目描述 最近 lxhgww\text{lxhgww}lxhgww 又迷上了投资股票,通过一段时间的观察和学习,他总结出了股票行情的一些规律。 通过一段时间的观察,lxhgww\text{lxhgww}lxhgww 预测到了未来 TTT 天内某只股票的走势,第 iii 天的股票买入价为每股 APiA
阅读全文
摘要:题目描述 一次考试共有n个人参加,第i个人说:“有ai个人分数比我高,bi个人分数比我低。”问最少有几个人没有说真话(可能有相同的分数) 输入输出格式 输入格式: 第一行一个整数n,接下来n行每行两个整数,第i+1行的两个整数分别代表ai、bi 输出格式: 一个整数,表示最少有几个人说谎 输入输出样
阅读全文
摘要:题目描述 字符序列的子序列是指从给定字符序列中随意地(不一定连续)去掉若干个字符(可能一个也不去掉)后所形成的字符序列。令给定的字符序列X=“x0,x1,…,xm-1”,序列Y=“y0,y1,…,yk-1”是X的子序列,存在X的一个严格递增下标序列<i0,i1,…,ik-1>,使得对所有的j=0,1
阅读全文