
动态规划
lasolmi
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
【DP】HDU 1011 Starship Troopers 树形DP
题目链接 #include #include #include #include #include using namespace std; const int maxn = 111; int n,m; vector G[maxn]; int dp[maxn][maxn]; bool vis[maxn]; int c[maxn],w[maxn];//c means the number原创 2014-08-29 18:51:26 · 466 阅读 · 0 评论 -
【多重背包】HDU 1059 Dividing
题目链接: #include #include #include using namespace std; int a[7]; int dp[121111]; int v,k; void ZeroOnePack(int cost,int weight) { for(int i=v;i>=cost;i--) dp[i] = max(dp[i] , dp[i-cost]原创 2014-08-29 22:52:23 · 500 阅读 · 0 评论