What are the conditions for an optimal binary search tree and what is its advantage?

Q & ACategory: Data StructureWhat are the conditions for an optimal binary search tree and what is its advantage?
Admin Staff asked 4 years ago

What are the conditions for an optimal binary search tree and what is its advantage?
a) The tree should not be modified and you should know how often the keys are accessed, it improves the lookup cost
b) You should know the frequency of access of the keys, improves the lookup time
c) The tree can be modified and you should know the number of elements in the tree before hand, it improves the deletion time
d) The tree should be just modified and improves the lookup time

1 Answers
Admin Staff answered 4 years ago

a) The tree should not be modified and you should know how often the keys are accessed, it improves the lookup cost