Union Street is Drop-in Union Find data struct for Leetcode problems written in Swift
Grad it here: UnionFind.swift
Union Find algorithm that I often has to write from scratch myself for Leetcode solutions. I have seen Union Find being implemented in a form of struct
or class
instead of inline functions with two arrays. This project exists so one can quickly copy-and-paste a UnionFind
data structure to a [Swift] Leetcode solutions.
- Simple AF
- Tested
Problems that can be solved with Union Find
data structure.