stackedList

{ Programming Tutorials }

Subscribe to stackedList

Get the latest updates & blog posts right to your inbox

bubble-sort
sorting algorithms

Bubble Sort

Bubble Sort is a simple brute force sorting algorithm. It works by comparing and swapping adjacent elements based on the sort condition. Bubble sort is implemented by using two loops and it can be enhanced by using a flag to exit the outer loop if there was no swapping in the inner loop.

Read More »
merge-sort
sorting algorithms

Merge Sort

Merge Sort is a divide and conquer algorithm. First we divide the array into two parts (left and right) using the middle index of the array to be sorted. Then we sort each part separately and finally combine the parts together in order.

Read More »
quick-sort
sorting algorithms

Quick Sort

Quick Sort is a very popular divide and conquer algorithm used for sorting collections. Quick sort works by selecting a pivot element and partition the array such that all the elements to the left of pivot are smaller that the pivot element.

Read More »