01背包
YCQ_Lancet
骐骥一跃,不能十步,驽马十驾,功在不舍
展开
-
The more, The Better HDU - 1561 树形dp,依赖背包
ACboy很喜欢玩一种战略游戏,在一个地图上,有N座城堡,每座城堡都有一定的宝物,在每次游戏中ACboy允许攻克M个城堡并获得里面的宝物。但由于地理位置原因,有些城堡不能直接攻克,要攻克这些城堡必须先攻克其他某一个特定的城堡。你能帮ACboy算出要获得尽量多的宝物应该攻克哪M个城堡吗?Input 每个测试实例首先包括2个整数,N,M.(1 = 0。当N = 0, M = 0输入结束原创 2017-11-17 19:12:24 · 243 阅读 · 0 评论 -
ACboy needs your help HDU - 1712 裸分组背包
ACboy has N courses this term, and he plans to spend at most M days on study.Of course,the profit he will gain from different course depending on the days he spend on it.How to arrange the M days for原创 2017-11-17 21:59:42 · 447 阅读 · 0 评论 -
E. Mishka and Divisors Codeforces Round #365 (Div. 2) 01背包
E. Mishka and Divisorstime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputAfter playing with her beautiful array, Mishka原创 2017-11-28 18:29:18 · 381 阅读 · 0 评论 -
I love sneakers! HDU - 3033 分组01背包 好题!
After months of hard working, Iserlohn finally wins awesome amount of scholarship. As a great zealot of sneakers, he decides to spend all his money on them in a sneaker store.There are sever原创 2017-11-20 19:37:47 · 342 阅读 · 0 评论 -
HDU 3449 Consumer 依赖背包
FJ is going to do some shopping, and before that, he needs some boxes to carry the different kinds of stuff he is going to buy. Each box is assigned to carry some specific kinds of stuff (that is to s原创 2017-11-21 16:45:24 · 148 阅读 · 0 评论