Merge Sort

A method of merging multiple sorted data sets into one sorted set

Most efficient method for linked lists!

Utilizing Divide and Conquer Algorithm

  • Divide data into minimum unit problems, then sort in order to get final results

    • top-down approach

Time Complexity

  • O(n log n)

Merge Sort Process

  1. Divide Phase

    • Continue dividing the entire data set until it becomes minimum-sized subsets

  2. Merge Phase

    • Sort and merge two subsets into one set

Divide Process Algorithm

Merge Process Algorithm

Last updated