会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
Loading
longwind's Blog
首页
新随笔
订阅
管理
2021年11月5日
多重背包问题 I
摘要: 相较与完全背包问题,多出来的条件是,每种物品的数量是一定的。 只需要多套一个循环,选1个2个3个一直到k个,k+1种可能循环一遍就行了。 #include<bits/stdc++.h> using namespace std; const int N=101; int n,m; int f[N];
阅读全文
posted @ 2021-11-05 15:27 longwind7
阅读(37)
评论(0)
推荐(0)