Skip to main content

Capstone Brief: The Finance Core

beginner12 min readLesson 83 of 148

One program composing structs, pointers, dynamic memory, files, and algorithms.

The mission

A personal finance core โ€” the computation and persistence heart of a ledger app, built from everything this course taught:

  • a Txn record: id, cents amount, category
  • operations: add, category totals, biggest expense, report line
  • validation at every boundary

What the graders check

The capstone battery runs against four functions:

  1. total_by_cat โ€” category-filtered sums
  2. biggest_idx โ€” the index of the largest expense
  3. after_balance โ€” running balance from a start value
  4. fmt_report โ€” one exact summary line, built with snprintf

Why these four

They force every layer at once: structs (records), pointers (arrays and out buffers), const discipline (read-only inputs), algorithms (max scan), and formatting (report). Change any piece and the whole thing still must hold together โ€” that is integration, the actual skill of engineering.

Beyond the battery

In a real project you would add: file persistence (module 16 โ€” a save/load pair), a menu loop (module 5-6), and unit tests per function. The sandbox battery verifies the core logic; the architecture around it is yours to build in the project gallery.

Now practice

Decomposition DrillSplit a problem into small testable functions, then compose them.3 challenges ยท ยท ~16 min