Skip to content

MeshanKhosla/redis-union-find

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

redis-union-find

This is an implementation of the Union Find/Disjoint Set data structure using Redis.

This project implements WeightedQuickUnion with Path Compression.

Why?

I think Disjoint Sets are really cool. I also think Redis is very cool.

Overview of Disjoint Sets

Read my blog post!


Made using Bun and Upstash Redis

I've also published to npm, and you can install it in your project using

npm install redis-union-find

or

bun add redis-union-find

and use it like this:

const uf = new UnionFind({
  redisToken: process.env.REDIS_TOKEN!,
  redisUrl: process.env.REDIS_URL!,
})

await uf.connect("Alice", "Bob")

About

A Union Find implementation using Redis

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published