Algorithms

15 posts
Sorting Algorithm - Shell Sort

Sorting Algorithm - Shell Sort

Shell Sort is a more refined version of insertion sort. This algorithm will change our array from completely random unsorted data to partially sorted data so that insertion sort may work faster. How This algorithm works by using increments, the increments can be found here. For this Article I will...

Sorting Algorithm - Selection Sort

Sorting Algorithm - Selection Sort

Selection Sort Selection Sort is a really easy to implement sorting algorithm, due to being inefficient on large datasets this algorithm is mostly used when memory is limited. How Selection sort work by having a list of numbers, it then goes through the list and finds the minimum number. When...

Sorting Algorithm - Quick Sort

Sorting Algorithm - Quick Sort

QuickSort is also a Divide And Conquer algorithm with a performance of $O(n * log(n))$, however in the worst case this becomes $O(n^2)$. How We start by picking an element which is called the pivot, then we will rearrange the array so that every element smaller than...

Sorting Algorithm - Merge Sort

Sorting Algorithm - Merge Sort

Merge Sort is a comparison algorithm that tries to sort the dataset by a Divide And Conquer method. The performance of this algorithm is $O(n*log(n))$. How We start by splitting the array up into separate elements, then we start by merging pairs together and we make sure...

Sorting Algorithm - Insertion Sort

Sorting Algorithm - Insertion Sort

Insertion sort is the core algorithm to know, it is also the easiest to understand and implement. The disadvantages however are that it is horribly slow. The recommendation is to use this algorithm when you are sorting really small tables (< 10). Insertion Sort is also used as the base for...

Sorting Algorithm - Heap Sort

Sorting Algorithm - Heap Sort

Heap Sort Heap sort works by using the heap datastructure. This sorting algorithm has a performance of $O(n*log(n))$ which makes it fast. How Heapsort works by first creating the heap datastructure, so let's say we have an array, it will then convert this array into a heap...

You’ve successfully subscribed to Xavier Geerinck
Welcome back! You’ve successfully signed in.
Great! You’ve successfully signed up.
Success! Your email is updated.
Your link has expired
Success! Check your email for magic link to sign-in.