๐ WAYPOINT LESSON
Checkpoint โ Break It Yourself
โญโญโญ advancedโณ 25 min read๐ Lesson 242 of 281
Strict-majority check: the honest O(n) count vs the plausible mode-heuristic with a >= boundary stumble. The tie-storm and exact-half tests are the adversarial shapes this module teaches.
Checkpoint โ Break It Yourself. Strict majority (> n/2) is a one-pass count with a strict comparison. The W embodies the two adversarial shapes from this module: the tie assumption (mode must be the majority โ false under ties) and the boundary stumble (>= instead of >, flipping the exactly-half case to a false YES). The tests are the shapes, made explicit: exact-half and tie-storm. When you can predict which tests will kill a plausible solution before running it, the adversarial skill has arrived.