MCQOPTIONS
Saved Bookmarks
This section includes 657 Mcqs, each offering curated multiple-choice questions to sharpen your Testing Subject knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
Consider the following statements related to the binary tree sort.I. Element can be added gradually as they become available |
| A. | nII. It needs extra memory space |
| B. | Statement I is true but Statement II is false |
| C. | Both Statement I and Statement II are false |
| D. | Both Statement I and Statement II are true |
| E. | Statement II is true but Statement I is false |
| Answer» D. Both Statement I and Statement II are true | |
| 2. |
Which of the following sorting algorithms can be considered as improvement to the binary tree sort? |
| A. | Heap sort |
| B. | Quick sort |
| C. | Selection sort |
| D. | Insertion sort |
| Answer» B. Quick sort | |
| 3. |
Binary tree sort is an in-place sorting algorithm. |
| A. | True |
| B. | False |
| Answer» C. | |
| 4. |
What is the best case time complexity of the binary tree sort? |
| A. | O(n) |
| B. | O(nlogn) |
| C. | O(n<sup>2</sup>) |
| D. | O(logn) |
| Answer» C. O(n<sup>2</sup>) | |
| 5. |
What is the worst case time complexity of the binary tree sort? |
| A. | O(n) |
| B. | O(nlogn) |
| C. | O(n<sup>2</sup>) |
| D. | O(logn) |
| Answer» D. O(logn) | |
| 6. |
In binary tree sort, we first construct the BST and then we perform _______ traversal to get the sorted order. |
| A. | inorder |
| B. | postorder |
| C. | preorder |
| D. | level order |
| Answer» B. postorder | |
| 7. |
Consider the original array 17 8 12 4 26. How many comparisons are needed to construct the BST on the original array? |
| A. | 5 |
| B. | 4 |
| C. | 7 |
| D. | 10 |
| Answer» E. | |