AVL tree
Sign in to saveAlso known as AVL trees, AVL-tree, AVL-trees
one kind of self-balancing binary search tree
Key facts
- Type
- Tree
- Invented by
- Georgy Adelson-Velsky and Evgenii Landis
via Wikipedia infobox
Wikidata facts
- Image
- AVLtreef.svg
Show 4 more facts
- Commons category
- AVL-trees
- Stack Exchange tag
- stackoverflow.com/tags/avl-tree
- time of discovery or invention
- 1962-00-00
- native label
- AVL tree
via Wikidata · CC0
~21 min read
Article
Animation showing the insertion of several elements into an AVL tree. It includes left, right, left-right and right-left rotations. Fig. 1: AVL tree with balance factors (green)
In computer science, an AVL tree (named after inventors Adelson-Velsky and Landis) is a self-balancing binary search tree. In an AVL tree, the heights of the two child subtrees of any node differ by not more than one; if at any time they differ by more than one, rebalancing is done to restore this property. Lookup, insertion, and deletion all take O(log n) time in both the average and worst cases, where