Intro to Mergesort Algorithm

Mergesort is a sorting algorithm, a classic example of a divide and conquer sorting algorithm.Divide and conquer is a technique to solve the problem by dividing it into smaller subsets which should be simple to easier to deal with.The result of small problems now should help to solve bigger subsets and eventually the entire problem.Let’s take a look at how mergesort works. Mergesort Algorithm The following is the steps for mergesort algorithm Recursively divide the array into smaller sub-arrays until each array has a single element. Recursively merge sub-arrays with sorted order until all the sub-arrays are merged. Note that READ MORE