摘要:
http://ac.jobdu.com/problem.php?pid=1499给N个有开始结束的且有价格的项目 安排项目的顺序 使总价值最大将项目按结束时间排序,01背包 ,dp[i] 表示到第i个项目,最大的价值是多少j从后往前遍历,更新符合 条件的的dp[i]#include#include#includeusing namespace std;struct data{ int ll,rr; int v;}s[10999];int dp[10999];int cmp(data x,data y){ return x.rr=1;j--){ i... 阅读全文
posted @ 2013-10-03 22:06 huhuuu 阅读(252) 评论(0) 推荐(0)
浙公网安备 33010602011771号