Category : C++ Source Code
Archive   : CPPTUT22.ZIP
Filename : USETIME.CPP

 
Output of file : USETIME.CPP contained in archive : CPPTUT22.ZIP
// Chapter 6 - Program 12

#include
#include "date.h"
#include "time.h"

void main(void)
{
date today;
time_of_day now, lunch(12, 15);

cout << "This program executed on " << today.get_date_string() <<
" at " << now.get_time_string() << "\n";

cout << "We are planning lunch at " << lunch.get_time_string() <<
" tomorrow.\n";

lunch.set_time(13);
cout << "We decided to move lunch to "<< lunch.get_time_string()
<< " due to a late meeting.\n";
}


// Result of execution

// This program executed on Jan 20, 1991 at 10:34:16
// We are planning lunch at 12:15:00 tomorrow.
// We decided to move lunch to 13:00:00 due to a late meeting.


  3 Responses to “Category : C++ Source Code
Archive   : CPPTUT22.ZIP
Filename : USETIME.CPP

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/