Skip to main content

Difference between Quick Sort and Merge Sort


Partitioning of the elements in the array :

In quick sort, the splitting of a list of elements is not necessarily divided into half

In merge sort, Array is always divided into half





Worst case complexity :

Worst case complexity of Quick Sort is O(n 2)

The worst case complexity of merge sort is O(n log n)





Best working field :

Quick sort works well on smaller array

Merge sort works well on any type of array





Speed :

Quick sort is faster than any other sorting algorithms for small data set.

Merge sort has the consistent speed in all type of data set





Additional space :

Quick sort requires less additional storage space

Merge sort requires more additional storage space





Effeiciency :

Quick sort is inefficient for larger arrays

Merge sort is more efficient for larger arrays





Sorting method :

Quick sort applies internal sorting method

Merge sort applies external sorting method