This repository contains an implementation of a red-black tree in Java.
A red-black tree is a type of self-balancing binary search tree that can be used to store data in key-value pairs. This implementation includes two main classes:
RedBlackTree
: contains the implementation of basic operations likesearch
,insert
,delete
,isEmpty
, anddisplay
.RedBlackTreeUserInput
: takes input from the user and switches it to know what operation the user wants to do.
To use this implementation of a red-black tree in your own project, you can simply copy the RedBlackTree.java
file into your project directory or clone this repository using Git : git clone repoLink