摘要: 题目链接:https://vjudge.net/problem/UVA-315 题目:求割点。 1 #include <iostream> 2 #include <cstdio> 3 #include <algorithm> 4 using namespace std; 5 6 const int 阅读全文
posted @ 2020-01-14 22:07 SummerMingQAQ 阅读(231) 评论(0) 推荐(0) 编辑
摘要: 题目链接:https://vjudge.net/problem/UVA-796 题目:裸的求桥,按第一个元素升序输出即可。 1 #include <iostream> 2 #include <cstdio> 3 #include <algorithm> 4 #include <vector> 5 u 阅读全文
posted @ 2020-01-14 17:59 SummerMingQAQ 阅读(251) 评论(0) 推荐(0) 编辑
摘要: 题目链接:https://vjudge.net/problem/POJ-3694 题目:给定一个连通图,求桥的个数,每次查询,加入一条边,问加入这条边后还有多少个桥。 思路:tarjan + 并查集 + lca(朴素) 先用tarjan缩点(成环缩点),并存下桥,把每个scc都存下一个源点(源点(b 阅读全文
posted @ 2020-01-14 13:24 SummerMingQAQ 阅读(274) 评论(0) 推荐(0) 编辑