Red-black Tree: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
Line 9: Line 9:


=Overview=
=Overview=
Red-black trees had been invented by Bayer (1972) and Guibas, Sedgewick (1978). They are a type of [[Binary_Search_Trees#Overview|binary search tree]] that self-balances on insertion and deletion, thus keeping its height to a minimum, which leads to efficient operations. Almost all [[Binary_Search_Trees#Supported_Operations|binary search tree operations]] have a running time bounded by the tree height, and in this case the tree height stays constant at log n, yielding O(log n) operations.
Red-black trees had been invented by Bayer (1972) and Guibas, Sedgewick (1978). They are a type of [[Binary_Search_Trees#Overview|binary search tree]] that self-balances on insertion and deletion, thus maintaining its height to a minimum, which leads to efficient operations. Almost all [[Binary_Search_Trees#Supported_Operations|binary search tree operations]] have a running time bounded by the tree height, and in this case the tree height stays constant at log n, yielding O(log n) operations.

Revision as of 04:52, 13 October 2021

External

Internal

Overview

Red-black trees had been invented by Bayer (1972) and Guibas, Sedgewick (1978). They are a type of binary search tree that self-balances on insertion and deletion, thus maintaining its height to a minimum, which leads to efficient operations. Almost all binary search tree operations have a running time bounded by the tree height, and in this case the tree height stays constant at log n, yielding O(log n) operations.