๐ WAYPOINT LESSON
Checkpoint: Modeling Under Contract
โญโญ intermediateโณ 22 min read๐ Lesson 104 of 225
Prove you can model with structs, enforce invariants through an API, and document ownership.
The task
Implement the declared BQueue API (see the challenge) exactly to
contract: FIFO order, the queue owns copies of its strings, -1 on
full/empty/bad args, NULL-tolerant, fixed capacity 8, strings up to 31
characters.
Passing this proves: struct modeling with invariants enforced behind an opaque handle, ring-buffer index arithmetic, and the discipline of return-code contracts.
Next module: strings as data โ buffers, boundaries, and parsing.