摘要: 省选模拟之辞旧迎新1 A. 神必的集合 不太理解 code #include<map> #include<set> #include<queue> #include<cmath> #include<cstdio> #include<vector> #include<cassert> #include 阅读全文
posted @ 2023-01-30 17:14 Chen_jr 阅读(50) 评论(0) 推荐(2)
摘要: 互测部分 1 https://www.cnblogs.com/Chencgy/p/16970117.html 2 A. 营救皮卡丘 跑弗洛伊德,搞出$i - > j$ 不经过比 $i ,j$ 编号大的点的最小花费 每个点都要走一遍,套路的拆点补流 $k$ 的流量直接从源点到 $1$ code #in 阅读全文
posted @ 2023-01-30 17:13 Chen_jr 阅读(34) 评论(0) 推荐(2)
摘要: 2 A. 集合划分 分治,设 $f_{l, r, 1 / 0, 1 / 0, x}$ 表示区间 $[l, r]$ 左边右边为 $S / T$ 集合,选择了 $x$ 个 $S$ 集合的方案数 合并区间发现$1 / 0$两维是一个矩阵乘法的形式,转移时候只转移合法的即可 最后一维的转移是卷积,直接 $n 阅读全文
posted @ 2023-01-30 17:13 Chen_jr 阅读(57) 评论(0) 推荐(1)