Build a B-tree storage engine (SQLite-style) (11 scenes)
Scene 5.5 · Delete and VACUUM — the file doesn't shrink
DELETE doesn't shrink the file — pages get freeblocks but never merge; only VACUUM rebuilds the file (at 2x disk cost).
Previously

Scene 5 ended with the tree symmetrically GROWING on insert. Junior intuition: it must symmetrically SHRINK on delete. It doesn't — and the difference is a half-step worth taking.

Scene 5.5
Delete and VACUUM — the file doesn't shrink
Diagram
Top: a 'DB FILE SIZE' readout (pages + bytes) above the same B-tree miniature from scene 5. Bottom-left: the zoomed leaf p17 — gray cells with 'free' tags are the freeblocks; the dashed red curve linking them is the freeblock chain. Bottom-right: the reclaim-mode panel — none / incremental_vacuum / VACUUM — with a utilization meter.
DB FILE SIZE2,500 pages · 10 MBUTILIZATION100%TREE — depth 3p1 (root)p2p3p4p11p12p13p14p15p16p17p18p19p20p21p22LEAF ZOOM — p17 (events lea…0 freeblocks#100 alice#101 bob#102 carol#103 dave#104 ellen#105 frank#106 grace#107 henry#108 iris#109 jackRECLAIM MODEnonefreeblocks scattered; file size unchangedincremental_vacuumreturns whole free pages; partial leaves st…VACUUMfull rebuild; needs ~2× disk transientlyUTILIZATION100%freeblocks scattered; file size frozen10 rows in leaf p17. We're about to DELETE 6 of them and watch the file size — and the freeblock chain.
Watch what 6 DELETEs do to leaf p17 and to the file. Cells gray out, the freeblock chain (red curve) snakes through them, the page-utilization meter drops to 40%. The DB FILE SIZE readout above the tree does NOT move.