Give your Room and Employee classes real behavior — not just data | Workbook p.36
You already built the Room and Employee classes in the previous exercise — they hold data (fields and getters/setters), but they don't do anything yet. Now it's time to add behavior.
A real hotel room has a lifecycle: a guest checks in, the room becomes occupied and starts to get dirty; when the guest checks out, the room is empty but still dirty; only after housekeeping cleans it can a new guest check in. Your Room class needs methods that model that flow.
An Employee punches a time card. When they punch in, you store their start time. When they punch out, you compute how many hours they worked and add it to hoursWorked. Time is given as an int in 24-hour format — 10 means 10:00 AM, 14 means 2:00 PM.
Bonus: Replace the two punch methods with a single punchTimeCard that figures out from the current state whether the employee is punching in or out, and acts accordingly.
punchTimeCard method that replaces both
The room is still dirty after checkout — housekeeping has to clean it before the next guest can check in.
Workbook 4a, p.36 — Module 2, Exercise 2: hotel-operations (Add Methods)