
Lesson 15-7: Case Study Maintenance
398 | Chapter 15
Name __________________________________________ Date _______________________
Section _________________________________________
TimeOfDay is a static variable for a time represented as hours, minutes, and seconds. The military
uses a 24-hour clock, so comparing static times returns the results you expect. In this lesson you
are to create and test a new class TwelveHourTime that inherits from TimeOfDay and adds a
char data field, which contains either an 'A' for AM or a 'P' for PM.
Exercise 1: Write the specification file for class TwelveHourTime.
Exercise 2: Write the implementation file for class ...