Of the following tree structure, which is, efficient considering space and time complexities?
(a) Incomplete Binary Tree
(b) Complete Binary Tree
(c) Full Binary Tree
(b) Complete Binary Tree.
Answer / sandeep vimal
By the method of elimination:
Full binary tree loses its nature when operations of insertions and deletions are done. For incomplete binary trees, extra storage is required and overhead of NULL node checking takes place. So complete binary tree is the better one since the property of complete binary tree is maintained even after operations like additions and deletions are done on it.
| Is This Answer Correct ? | 0 Yes | 0 No |
What are the 3 types of variables?
Which data structure is used to perform recursion?
Why do we need searching algorithms?
What is sorting explain?
What data structure does a binary tree degenerate?
When would you use a hashmap?
What is different between array and list?
What is mergesort and hashtable?
Define depth and height of a tree?
What is bubble sort and quick sort?
Which is the parent class of linkedlist class?
What is a treemap used for?