C++Intermediateabout 8 hours16 lessons
Recommended first: Reactor Core
Write the inventory system for the Larkspur Conservation Lab, a restoration workshop, as one growing C++ program. Every lesson photographs your program's memory: variables on the workbench, blocks in the vault, arrows for pointers, badges for who owns what, a logbook of every construction and destruction, and a running count of copies against moves. By the end the audit reads zero leaks.
Each lesson adds one working part to your build.
Chapter 1
Addresses, pointers and references, arrays, the stack and its lifetimes, then the heap with new and delete. Your first photos of the lab's memory.
Chapter 2
Tie every delete to a scope with RAII, then make a class that owns memory copy and move correctly. Watch constructors, destructors, copies and moves in the logbook.
Chapter 3
Decide which special members a class really needs, let std::unique_ptr do the owning, and make your types pleasant and safe to use with operators and const.
Chapter 4
Read a real manifest from input, fail safely with your own exceptions, put one registry in charge of every piece, and finish with a full run that leaks nothing.