摘要: 题目 解析: 本质是个二分图带权匹配问题,建图后用费用流实现即可。 code: #include <iostream> #include <algorithm> #include <cstdio> #include <queue> #include <cstring> using namespace 阅读全文
posted @ 2021-07-31 11:51 Tarjan_Zeng 阅读(47) 评论(0) 推荐(0)
摘要: 题目 解析: 点只能经过一次就拆成两个点,连一条容量为1费用为0的边即可。 code: #include <iostream> #include <algorithm> #include <cstdio> #include <queue> using namespace std; const int 阅读全文
posted @ 2021-07-31 10:35 Tarjan_Zeng 阅读(42) 评论(0) 推荐(0)