Question: Consider the following class Date definition which appears in header file date.h. The file date.co which contains the implementation of the class is not given.


Consider the following class Date definition which appears in header file date.h. The file date.co which contains the implementation of the class is not given. Assume that the implementation performs error checking and ensure that the Date object is always in valid state. #ifndef,-DATE. H- #define-DATE. H- class Date public: Date); I/ default constructor: it sets the date to 1/1/2001 void setDay(int d); void setMonth(int m); void setYear(int y); int getDay0 const; int getMonth0 const; int getYearO const; void print0 const; I/ display date in the following format mm/dd/yyvy private: int-day,-month,-year
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
