Insertion sort is a simple sorting algorithm where each iteration removes one element from an input data set and inserts it into its correct position within a partially sorted list until all elements are inserted.
congrats on reading the definition of Insertion Sort. now let's actually learn it.
Selection Sort: A sorting algorithm that repeatedly selects the smallest element from the unsorted part and moves it to the sorted part.
Merge Sort: A divide-and-conquer algorithm that divides an array into two halves, sorts them separately, and then merges them back together.
Quick Sort: A divide-and-conquer algorithm that picks an element as a pivot, partitions the array around this pivot, and recursively sorts subarrays before and after the pivot.