Day 9/60: Sliding window patterns
Today's note was about using a stable invariant so sliding window patterns feels like a process instead of a trick. I kept coming back to the same checks: name the exact window, prefix, or pointer region each variable owns, reuse prior work instead of recomputing the same range each iteration, and test boundary sizes first because they expose weak invariants quickly.
The failure mode worth watching is moving boundaries before stating what region they actually represent. If that happens, the implementation usually looks busy while the invariant is already gone.
