This page assumes you have seen nothing. Before you read the parent note, you should recognise every squiggle it throws at you. We build them one at a time, each on top of the one before it, each anchored to a picture.
Look at figure below: the strip has cells, and above each cell sits a small number — that number is its position, called an index. Programmers count indices starting at 0, so the first cell is index 0, the second is index 1, and so on.
Why does the topic need this? Every step of merge sort talks about "the front element of a list" or "the box at index i" — without indices we cannot point at which number we mean.
The symbol ≤ means "less than or equal to". Why or equal and not just "less than"? Because two boxes are allowed to hold the same number and the list is still sorted — think of two cards both showing 3 sitting side by side. That tiny "or equal" is exactly what makes the topic's stability discussion possible later.
The parent writes mid = len(a) // 2 and later ⌊n/2⌋ and ⌈n/2⌉. Let us earn those.
Why do we need to drop the remainder? An index must be a whole number — there is no "box number 3.5". So when we split a list of length 7, the cut lands at box 3, giving a left half of 3 boxes and a right half of 4.
So for length n=7: the left half has ⌊7/2⌋=3 boxes, the right half has ⌈7/2⌉=4 boxes. The two floor/ceiling brackets are just the precise way of saying "if it doesn't split evenly, the right side gets the extra box".
The parent's merge_sort calls merge_sortinside itself. That is recursion.
Why does the topic need this? "Divide and conquer" is recursion — the whole speed argument depends on the problem shrinking by half each call. See Recursion and Induction for the deeper machinery; the proof of correctness on the parent page leans on it directly.
The merge routine walks both lists at once with these two fingers, always comparing the two boxes the fingers rest on and taking the smaller. This picture is the merge algorithm.
The parent says merge is Θ(n) and the whole sort is Θ(nlogn). Three symbols to unpack.
Why this exact tool and not another? Merge sort halves the list at every level. The natural question "how many levels of halving are there?" is precisely what a base-2 logarithm answers — that is why log (and not, say, n) appears in the running time. The Master Theorem turns the recurrence into this log automatically.
Recall Quick log check
log216=?
::: 4, because 16→8→4→2→1 is four halvings.
Why the topic needs this: the recurrence is the bridge from "the algorithm's shape" to "its running time". You solve it by drawing a recursion tree (each node splits into two half-size children), which the parent does to reach Θ(nlogn).