07 2021 档案
摘要:和原板子区别不大,更符合我的代码习惯 #include<cstdio> #include<algorithm> #include<cstring> #include<queue> using namespace std; const int maxn = 2e5+5; int n, m, head[
阅读全文
摘要:#include<cstdio> #include<algorithm> #include<cstring> #include<queue> using namespace std; const int maxn = 2e5+5; struct mint { int nxt, v, w; }e[ma
阅读全文
摘要:二进制优化用于多重背包中。 (1)多重背包模板: long long dp[maxn], n, W, v[maxn], w[maxn], m[maxn]; //n是物品种类,W是背包总容量,v[i]是第i种物品的价值,w[i]是第i种物品的重量,m[i]是第i种物品的件数 for(int i = 1
阅读全文

浙公网安备 33010602011771号