夜语声烦-
夜语声烦-
全部文章
题解
归档
标签
去牛客网
登录
/
注册
夜语声烦-的博客
全部文章
/ 题解
(共3篇)
题解 | #[NOIP2013]记数问题#
好吧,说实话我还以为是计数类DP,没想到完全想复杂了,不过我这是万能的,可以求任意x~y直接任意z的出现次数,用前缀和就行cnt(y,z) - cnt(x-1,z) # include <iostream> # include <cmath> using namespace ...
C++
动态规划
2022-02-07
1
539
题解 | #简单的烦恼#
完全背包 #include<iostream> #include<algorithm> #include<cstring> using namespace std; int t; int n,m; int a[410]; int dp[80010]; int ...
C++
动态规划
2021-12-10
1
402
题解 | #总分#
完全背包 #include<iostream> using namespace std; const int N = 1e4 + 10; int n,m; int v[N],w[N],f[N]; int main() { cin >> m >> n; ...
C++
动态规划
2021-12-08
2
350