Question 14958 – DSSSB TGT 2017
February 20, 2024
Question 11772 – Sorting
February 20, 2024
Question 14958 – DSSSB TGT 2017
February 20, 2024
Question 11772 – Sorting
February 20, 2024

Question 9327 – Sorting

Which one of the following in place sorting algorithms needs the minimum number of swaps?

Correct Answer: C

Question 17 Explanation: 
Selection sort requires minimum number of swaps i.e O(n). The algorithm finds the minimum value, swaps it with the value in the first position, and repeats these steps for the remainder of the list. It does no more than n swaps, and thus is useful where swapping is very expensive.
A
Quick sort
B
Insertion sort
C
Selection sort
D
Heap sort
0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
error: Alert: Content selection is disabled!!