A sorting technique is called stable if
2017
A sorting technique is called stable if
Answer: C. Relative order of occurrence of non-distinct elements is maintained — A sorting algorithm is stable if it preserves the relative order of equal elements after sorting. This means that if two items have the same key, their…
- A.
If it takes O(n log n) time
- B.
It uses divide and conquer technique
- C.
Relative order of occurrence of non-distinct elements is maintained
- D.
It takes O(n) space
Attempted by 1007 students.
Show answer & explanation
Correct answer: C
A sorting algorithm is stable if it preserves the relative order of equal elements after sorting. This means that if two items have the same key, their original sequence remains unchanged in the sorted output.
Explore the full course: Iocl Engineers Officers Grade A Paper 2
Loading lesson…