COMPUTER SCIENCE AND ENGINEERING
DATA STRUCTURES
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
AVL tree
|
|
Red-black tree
|
|
Lemma tree
|
|
None of the above
|
Detailed explanation-1: -Answer: Binary search tree whose left sub tree and right sub tree differ in height by one unit is called AVL trees. Explanation: An AVL tree is the binary search tree in which every sub tree is an AVL tree but is not entirely balanced.
Detailed explanation-2: -Self Balancing Binary Search Tree This means that in an AVL tree the difference between left subtree and right subtree height is at most one. AVL tree is a self-balancing binary search tree.
Detailed explanation-3: -AVL tree is a self-balancing Binary Search Tree (BST) where the difference between heights of left and right subtrees cannot be more than one for all nodes.
Detailed explanation-4: -In Binary Search Tree, In AVL Tree, every node does not follow the balance factor. In AVL Tree, every node follows the balance factor i.e. 0, 1, -1. 2. Every Binary Search tree is not an AVL tree.
Detailed explanation-5: -An AVL tree is a self-balancing binary search tree where the difference between heights of left and right subtrees cannot be more than one. This difference is known as a balance factor. In the AVL tree, the values of balance factor could be either-1, 0 or 1.