Merge Sort Program using JavaScript

So I was trying to create a Merge sort program using JS. Before trying to make the program we first have to understand what is the concept of merge Sort. To get a good example I went to wikipedia where I found very interesting GIF which explained the the basics of Merge sort.

In Merge sort you first have to divide the whole list into two halves and keep doing it till the number of values in the each divided list is one. As we know that if there is only one element in the list then we can take it as already sorted. Now we are going to recombine them one by one in the similar sense in which we have divided it. While recombining them we will make sure that the element added are sorted.

So the program that I created went to some errors and I am still looking into them. Whenever it is complete I will edit this post.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s