home *** CD-ROM | disk | FTP | other *** search
/ CD/PC Actual 13 / CDA13.ISO / cdactual / demobin / share / program / C / ANSICPP.ZIP / TIMEDAY.H < prev    next >
Encoding:
C/C++ Source or Header  |  1990-07-24  |  394 b   |  22 lines

  1. // ex09001
  2. // Header file to define the Time class
  3. // ---------- timeday.h
  4.  
  5. #ifndef TIMEDAY_H
  6. #define TIMEDAY_H
  7.  
  8. #include <iostream.h>
  9. //
  10. // A Time Class
  11. //
  12. class Time    {
  13.     int hours, minutes, seconds;
  14. public:
  15.     Time(int hr, int min, int sec)
  16.         { hours = hr; minutes = min; seconds = sec; }
  17.     void display()
  18.         { cout << hours << ':' << minutes << ':' << seconds; }
  19. };
  20.  
  21. #endif
  22.