Implemented a red black tree