MCQOPTIONS
Saved Bookmarks
This section includes 10 Mcqs, each offering curated multiple-choice questions to sharpen your Comb Sort Multiple Choice knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
What is the advantage of comb sort over merge sort? |
| A. | Comb sort is an in place sorting algorithm |
| B. | Comb sort is a stable sorting algorithm |
| C. | Comb sort is more efficient |
| D. | It has no advantage |
| Answer» B. Comb sort is a stable sorting algorithm | |
| 2. |
What is the best case time complexity of comb sort and bubble sort respectively? |
| A. | O(n<sup>2</sup>) and O(n log n) |
| B. | O(n log n) and O(n) |
| C. | O(n) and O(n<sup>2</sup>) |
| D. | O(n<sup>2</sup>/2<sup>a</sup>) (a=number of increment) and O(n<sup>2</sup>) |
| Answer» C. O(n) and O(n<sup>2</sup>) | |
| 3. |
Comb sort is a stable sorting algorithm. |
| A. | True |
| B. | False |
| Answer» C. | |
| 4. |
The given array is arr={7,4,5,8,1,2}. The number of iterations required to sort the array using comb sort and bubble sort respectively will be _______ |
| A. | 7 and 8 |
| B. | 5 and 6 |
| C. | 5 and 5 |
| D. | 4 and 5 |
| Answer» E. | |
| 5. |
Auxiliary space used by comb sort is _______ |
| A. | O(1) |
| B. | O(n) |
| C. | O(log n) |
| D. | O(n log n) |
| Answer» B. O(n) | |
| 6. |
The gap value after 3 iterations in an array with 6 elements will be _______ |
| A. | 4 |
| B. | 3 |
| C. | 2 |
| D. | 1 |
| Answer» D. 1 | |
| 7. |
What is the worst case time complexity of comb sort? |
| A. | O(n<sup>2</sup>) |
| B. | O(n log n) |
| C. | O(n) |
| D. | O(n<sup>2</sup>/2<sup>a</sup>) (a=number of increment) |
| Answer» B. O(n log n) | |
| 8. |
The initial gap between two elements being compared _______ |
| A. | is equal to number of elements in the array |
| B. | is equal to 1.3 |
| C. | depends on the number of iterations |
| D. | depends on the compiler being used |
| Answer» B. is equal to 1.3 | |
| 9. |
The gap between two elements being compared shrinks by a factor of _______ after every iteration. |
| A. | 1.1 |
| B. | 1.2 |
| C. | 1.3 |
| D. | 1.4 |
| Answer» D. 1.4 | |
| 10. |
Comb sort is an improved version of _______ |
| A. | Selection sort |
| B. | Bubble sort |
| C. | Insertion sort |
| D. | Merge sort |
| Answer» C. Insertion sort | |