In selection sort, what is the main operation performed in each iteration?

  • Doubling the size of the sorted portion
  • Finding the minimum element in the unsorted portion and swapping it with the first element of the unsorted part
  • Multiplying elements in the unsorted portion
  • Randomly rearranging elements in the unsorted portion
The main operation in each iteration of selection sort is finding the minimum element in the unsorted portion and swapping it with the first element of the unsorted part. This gradually builds the sorted portion.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *