Question: For a binary search tree, the best possible order in which elements are added to the tree would include: a. Smallest value first b. Largest
For a binary search tree, the best possible order in which elements are added to the tree would include:
| a. | Smallest value first | |
| b. | Largest value first | |
| c. | Middle value first | |
| d. | The order in which values are inserted does not matter |
For a heap, the best possible order in which elements are added to the heap would include: (assume the largest value is stored at the root)
| a. | Largest value last | |
| b. | The order in which values are inserted does not matter | |
| c. | Smallest value last | |
| d. | Middle value last |
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
