// Program that tests the date class #include #include "date.h" void main(void) { date d; d.AssignDate(12,31,1999); // december 31, 1999 d.DisplayShort(); // 12/31/99 cout << endl; // so it has a new line d.DisplayVerbose(); // December 31, 1999 cout << endl; // so it has a new line d.NextDay(); // increment to the next big day!! d.DisplayShort(); // 1/1/0 cout << endl; // so it has a new line d.DisplayVerbose(); // January 1, 2000 cout << endl; // so it has a new line // now let's test a leap year d.AssignDate(2,27,2000); d.NextDay(); // 2/28/00 d.NextDay(); // 2/29/00 d.DisplayShort(); // we should see 2/29/0 cout << endl; d.DisplayVerbose(); // we should see February 29, 2000 cout << endl; }