Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UnionFind ¶
type UnionFind struct {
// contains filtered or unexported fields
}
我们的第一版Union-Find
func Constructor ¶
func (*UnionFind) IsConnected ¶
查看元素p和元素q是否所属一个集合 O(1)复杂度
func (*UnionFind) UnionElements ¶
合并元素p和元素q所属的集合 O(n) 复杂度
Click to show internal directories.
Click to hide internal directories.