CSE Roadmap

Core tier · about 4 hours · 6 parts

Part 1 of 6 · 1 min read

Why this page comes fifth in Level 6

In this module you will

  • Apply the five-step method to a design that talks to a bank.
  • Model the ATM session as a small state machine.
  • Plan a cash payout from limited notes before touching the account.
  • Order the steps so that a machine fault never charges the customer.
  • Enforce limits and PIN attempts in the class that owns the data.

The ATM adds a new idea to the vending machine: money moves between two systems, the machine and the bank, and either side can fail part-way. The ordering of steps and the undo of a charge are the heart of the answer. It reuses the state idea (module 4) and the note search that is like making change. This page uses the five steps of Level 0, module 4, and the error rules of Level 5, module 1. No book was supplied for this track, so the content is common practice, not from the books. The Java code was compiled and run before it was written here. Numbers marked "made up" only show the idea.