摘要: 传送门:http://www.lydsy.com/JudgeOnline/problem.php?id=3685 【题解】 写个set+fread即可。 # include <set> # include <stdio.h> # include <string.h> # include <iostr 阅读全文
posted @ 2017-06-01 16:11 Galaxies 阅读(177) 评论(0) 推荐(0)
摘要: 传送门:http://www.lydsy.com/JudgeOnline/problem.php?id=1391 【题解】 简单最小割建模。 加当前弧优化!!! # include <queue> # include <stdio.h> # include <string.h> # include 阅读全文
posted @ 2017-06-01 15:54 Galaxies 阅读(212) 评论(0) 推荐(0)
摘要: 传送门:http://www.lydsy.com/JudgeOnline/problem.php?id=1070 【题解】 建图非常巧妙 需要仔细思考 我们考虑对第i个工人,倒数第j次修车建点,对于这里面每个点,连到T,流量1费用0表示只能用一次(废话)。 对于每辆车k,都可以连到这个点,流量1,费 阅读全文
posted @ 2017-06-01 15:27 Galaxies 阅读(153) 评论(0) 推荐(0)
摘要: 传送门:http://www.lydsy.com/JudgeOnline/problem.php?id=1066 【题解】 网络流,考虑建模,拆点来满足限制跳多少次即可。 第2000个AC! # include <queue> # include <stdio.h> # include <strin 阅读全文
posted @ 2017-06-01 14:48 Galaxies 阅读(157) 评论(0) 推荐(0)
摘要: 传送门:http://www.lydsy.com/JudgeOnline/problem.php?id=1123 【题解】 tarjan算割点的时候顺便统计即可。 割点的条件是 low[to[i]]>=dfn[x],说明删掉点x这一段就不和其他联通了。 先算不包含祖先的其他连通块的贡献,最后加包含祖 阅读全文
posted @ 2017-06-01 14:28 Galaxies 阅读(388) 评论(0) 推荐(0)
摘要: 传送门:http://www.lydsy.com/JudgeOnline/problem.php?id=1558 【题解】 这题恶心死人了啊。。 网络上题解很多都是看代码看代码。。真是太不负责任了。。我这里详细说一下吧。。 题解在代码下面。 # include <stdio.h> # include 阅读全文
posted @ 2017-06-01 11:04 Galaxies 阅读(943) 评论(0) 推荐(3)