CSCI 1300, Section 100
Hints on Assignment 3


1. The amount of time that the program should go forward or backward may be more than 24 hours.  (My apologies to the person who asked me this question by email.  Some email was deleted before I could respond.)

2. If you name your executable "time.exe", you will not be able to run in, because time is a DOS command, and the DOS commmand "time" will run instead.

3. if you want to print out minutes and seconds so that there is a leading zero for values less than 10, you can use the following code:

cout << setfill('0') << setw(2) << x;

for the int variable x.  setw(2) sets the output width to two columns.  By default the output is right justified with leading spaces.  However, the setfill('0') replaces leading spaces with leading zeroes.  Remember that to use setw() and setfill() you need to include iomanip.h instead of iostream.h.