๐ WAYPOINT LESSON
The three bankable cores
โญโญโญ advancedโณ 10 min read๐ Lesson 223 of 256
The count, the existence check, the first-match-with-sentinel โ implement, verify, and leave alone.
Banking behaviors. Every hard FRQ contains a soft core โ a behavior you can implement correctly in two minutes. Banking it means: implement it, verify it against the example, and LEAVE it alone. Resist the urge to refactor toward elegance; partial-credit time is spent on points, not beauty.
The three bankable cores, in exam-frequency order:
- The count (or sum) with one condition โ almost every FRQ has one.
- The existence check โ return true the moment a condition fires; three lines, one early return.
- The single pass with an early sentinel โ first-match with a default return at the end.
When the checkpoint asks for the full class, bank coldHours()
first, then hasWarmDay(), and only then attempt firstBelow().
If the clock runs out mid-firstBelow, you still banked two of
three โ the exam version of never losing the whole game.
โก Now practice
Ready to CodePartial credit drillThe three bankable cores, then the assembly under simulated time pressure.
3 challenges ยท ยท ~45 min