Consider a tree T storing 100,000 entries. What is the worst-case height of T in the following cases?

(a) T is an AVL tree.
(b) T is a (2,4) tree.
(c) T is a red-black tree.
(d) T is a splay tree.
(e) T is a binary search tree.

Respuesta :

abarde

Answer:

Step-by-step explanation:

a.) The worst-case height of an AVL tree or red-black tree with 100,000 entries is 2 log 100, 000.

b.) A (2, 4) tree storing these same number of entries would have a worst-case height of log 100, 000.

c.) A red-black tree with 100,000 entries is 2 log 100, 000

d.) The worst-case height of T is 100,000.

e.)  A binary search tree storing such a set would have a worst-case height of 100,000.