Listing 1 Introduces a function to compare dates

// date4.h

class Date
   int month;
   int day;
   int year;

   // Constructors
     {month = day = year= 0;}
   Date(int m, int d, int y)
     {month = m; day = d; year = y;}

   // Accessor Functions
   int get_month() const
     {return month;}
   int get_day() const
     {return day;}
   int get_year() const
     {return year;}

   Date * interval(const Date&) const;
   int compare(const Date&) const;

// End of File