Pick up each element and slide it into its correct position — like sorting a hand of cards
Insertion Sort builds the sorted portion one element at a time. It picks the next unsorted element (the "key") and slides it leftward past any larger elements until it finds its correct position — just like inserting a playing card into a sorted hand.
Time complexity: Best case O(n) when the array is already sorted (each element compared once, no shifts needed). Average and worst case O(n²) — worst case occurs when the array is in reverse order.
Space complexity: O(1) — sorts in place, only needs a temporary variable to hold the key.
Key insight: The sorted region grows from left to right. At each step, everything to the left of the key is already sorted. Elements larger than the key shift one position right to make room.