Skip to content

Implementations of some of the classic "tree" data structures in Rust, including unbalanced and balanced binary trees.

Notifications You must be signed in to change notification settings

joeclark-phd/jtree

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jtree

This package contains my own implementations of some of the classic "tree" data structures in Rust, such as:

  • Jbst: a simple binary search tree storing unique values in order (i.e. an ordered set)
  • Jblst: a simple binary (list-like) search tree allowing duplicate entries (i.e. an ordered list)
  • Javlt: an AVL balanced binary searh tree, storing unique values in order (i.e. an ordered set) with guaranteed O(log(n)) lookups

operations

Each tree type should support these operations:

  • Adding a unique value
  • Adding a vector of unique values
  • Deleting a value
  • Checking if a value exists in the tree
  • Returning the values as an ordered vector (in either direction)
  • Pretty-printing the tree

Some types may support:

  • Mutating values in place
  • Adding non-unique values

usage

See individual modules for rustdocs. Run tests with:

cargo test

Build the docs with:

cargo doc

About

Implementations of some of the classic "tree" data structures in Rust, including unbalanced and balanced binary trees.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages