What is the time complexity for storing the maximum number of elements in Van Emde Boas tree if M is the maximum number of elements?

Category: QuestionsWhat is the time complexity for storing the maximum number of elements in Van Emde Boas tree if M is the maximum number of elements?
Editor">Editor Staff asked 5 months ago

What is the time complexity for storing the maximum number of elements in Van Emde Boas tree if M is the maximum number of elements?
 
(a) O (log M)
 
(b) O (M!)
 
(c) O (M)
 
(d) O (1)
 
This interesting question is from Trees topic in division Trees of Data Structures & Algorithms I
 
The question was posed to me during an internship interview.

1 Answers
Editor">Editor Staff answered 5 months ago

Correct option is (c) O (M)
 
The best I can explain: In order to store the maximum number of elements in Van Emde Boas data structure where M is the maximum number of elements, the tree has great efficiency for storing them. So the time complexity for worst case is found to be O (M).


Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17

Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17

Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17

Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17
Articles: 40702