Free Low-level design lessonsLow-level design · Stage 0 · The approach · Step 1
From requirements to classes
A repeatable method for starting any low-level design: clarify, find entities, assign responsibilities, then refine. About 13 minutes.
Which is the best place to put a computation that needs a ticket's entry time and the vehicle's type?
- AWith the Ticket (or a fee policy that receives the ticket), where that data lives
- BIn the ParkingLot, since it knows everything
- CIn the main method
Show the answer
With the Ticket (or a fee policy that receives the ticket), where that data lives. Behaviour follows the data it uses.
4 questions on this idea
Short questions that apply the idea to new cases: trace it, work out a number, put steps in order. A wrong answer explains itself.
Answer them in your browserFree account, no card. Your progress is saved, and the idea comes back in a quick review later.
Sign up free to solve