摘要:
// by TheSky233 (www.luogu.com.cn/user/501865) // 转载请标明出处 qwq #include <bits/stdc++.h> using namespace std; template<typename T> T readIn(){ T x(0),f( 阅读全文
posted @ 2023-01-20 21:55
DataErr0r
阅读(62)
评论(0)
推荐(0)
摘要:
复杂度上界为 $\Theta(n^2m)$,实际效率远高于此。 #include <bits/stdc++.h> using namespace std; const int N=5e5+5; const int M=1e6+5; const int MN=1e3+5; typedef long l 阅读全文
posted @ 2023-01-20 19:43
DataErr0r
阅读(49)
评论(0)
推荐(0)
摘要:
- 前言 本文主要介绍 Tarjan 算法的「强连通分量」「割点」「桥」等算法。 争取写的好懂一些。 - 「强连通分量」 - 何为「强连通分量」 在有向图中,如果任意两个点都能通过直接或间接的路径相互通达,那么就称这个有向图是「强连通」的。 如果这个有向图的子图是「强连通」的,我们就称这个子图为「强 阅读全文
posted @ 2023-01-20 11:26
DataErr0r
阅读(43)
评论(0)
推荐(1)
摘要:
珂朵莉树 $\tt 0x00$ 起源 起源于 CodeForces 的一题 CF896C,当时出题人提供了这种做法,在随机数据下均摊复杂度比较优秀。 正统名字好像叫颜色段均摊,由于题目也得名于 $\overset{\tt{Old}}{\texttt{珂}}\overset{\tt{Driver}}{ 阅读全文
posted @ 2023-01-20 11:13
DataErr0r
阅读(107)
评论(0)
推荐(0)
摘要:
$\texttt{0x01}$ 前言 Splay 树(伸展树)是一棵二叉搜索树,由 Daniel Sleator 和 Robert Tarjan 于 1985 年发明。它凭借旋转可以有 $O(\log n) $ 插入,删除等的较优秀的时间复杂度。 前置芝士:普通二叉排序树。 推荐博客: https: 阅读全文
posted @ 2023-01-20 11:12
DataErr0r
阅读(34)
评论(0)
推荐(0)
摘要:
- 闲话 LCT 优秀博客: $\color{black}{\textsf{F}}\color{red}{\textsf{lashHu}}$ 大佬的 cnblogs:https://www.cnblogs.com/flashhu/p/8324551.html - 动态树 Link-Cut Tree 阅读全文
posted @ 2023-01-20 10:17
DataErr0r
阅读(54)
评论(0)
推荐(0)