1.

Merge sort can be implemented using O(1) auxiliary space.(a) true(b) falseI got this question in examination.My question is from Sorting in portion Sorting of Data Structures & Algorithms II

Answer»

Correct choice is (a) true

The explanation is: Standard MERGE sort requires O(N) SPACE to merge TWO sorted arrays. We can optimize this merging process so that it takes only CONSTANT space. This version is known as in place merge sort.



Discussion

No Comment Found

Related InterviewSolutions