Mental Model
Split the array into two halves, find the max subarray in the left, right, and crossing the middle, then pick the best.
Analogy: Imagine cutting a chocolate bar into two parts, finding the best piece on the left, the best on the right, and the best piece that crosses the cut, then choosing the tastiest piece overall.
Array: [ -2, 1, -3, 4, -1, 2, 1, -5, 4 ] Split: [ -2, 1, -3, 4, -1 ] | [ 2, 1, -5, 4 ] Left max subarray [4] ↑ Right max subarray [4] ↑ Cross max subarray [4, -1, 2, 1] ↑