1.

Which of the following algorithm implementations is similar to that of an insertion sort?(a) Binary heap(b) Quick sort(c) Merge sort(d) Radix sortI had been asked this question in an online interview.Asked question is from Insertion sort topic in chapter Sorting of Data Structures & Algorithms II

Answer»

Correct option is (a) Binary heap

The EXPLANATION is: INSERTION sort is SIMILAR to that of a binary heap ALGORITHM because of the USE of temporary variable to swap.



Discussion

No Comment Found

Related InterviewSolutions