摘要:
1.P2240 【深基12.例1】部分背包问题 - 洛谷 | 计算机科学教育新生态 (luogu.com.cn) 算性价比,进行排序来进行局部最优解 1 #include<bits/stdc++.h> 2 using namespace std; 3 4 int t,n; 5 6 struct no 阅读全文
posted @ 2023-11-23 22:27
rw156
阅读(31)
评论(0)
推荐(0)
摘要:
1.区间划分 acwing 905 按照区间右端点来排序,如果当前点能覆盖到则继续往下读,如果不能覆盖到则点数加一,该点更新为下一个区间的最右端点 1 #include<bits/stdc++.h> 2 using namespace std; 3 4 int n; 5 const int N = 阅读全文
posted @ 2023-11-23 20:08
rw156
阅读(17)
评论(0)
推荐(0)

浙公网安备 33010602011771号