摘要:
多重背包问题可以用单调队列进行优化 原理见:提高课1.3.1 背包模型(一) 离题:6. 多重背包问题 III 单调队列的deque实现如下: #include<bits/stdc++.h> using namespace std; int v[1010]; int w[1010]; int s[1 阅读全文
摘要:
1、分治 2、记忆化 3、动态规划 https://codingcompetitions.withgoogle.com/codejam/round/0000000000877ba5/0000000000aa9280#problem #include <bits/stdc++.h> using nam 阅读全文