CodeForces 712D Memory and Scores
题目链接:http://codeforces.com/contest/712/problem/D
dp
因为每轮Memory和Lexa能取的都在[-k,k],也就是说每轮两人分数的变化量在[-2k,2k];
故可以定义状态:dp[times][diff]为第times次Memory和Lexa的分数差为diff的方案数.
而dp[times][diff]可以从dp[times-1][diff
转载
2016-09-22 14:00:42 ·
375 阅读 ·
0 评论