What is the advantage of selection sort over other sorting techniques?

2023

What is the advantage of selection sort over other sorting techniques?

  1. A.

    It requires no additional storage space

  2. B.

    It is scalable

  3. C.

    It works best for inputs which are already sorted

  4. D.

    It is faster than any other sorting technique

Attempted by 334 students.

Show answer & explanation

Correct answer: A

Answer: A

Explanation: Selection sort is an in-place sorting algorithm, meaning it sorts the elements by rearranging them within the original array without requiring additional storage space. This is achieved by repeatedly selecting the smallest element from the unsorted portion and swapping it into the correct position. Since no extra array or data structure is needed, it uses O(1) auxiliary space, making it memory-efficient.

Explore the full course: Coding For Placement