create a class called Date that contains data members representing day month, year of a particular date. A. Add a constructor who initializes the value of date as 1/1/2001 and displays the date by...


create a class called Date that contains data members representing day month, year of a


particular date.


A. Add a constructor who initializes the value of date as 1/1/2001 and displays the date by calling a


member function to-string that represents the date in the form of “Day/Month/year”.


B. Output the Date in multiple formats such as


a. DD YYYY


b. MM/DD/YYYY


c. DD.MM.YYYY


d. June 14, 2001


C. Use overloaded constructor to create Date objects initialized with dates of the format in part


(b).


D. Create a Date constructor that reads the system date using standard library function of the


header and sets the data members.


a. https://onlinegdb.com/NaakQKYJI (Refer this code for the usage of ctime)


b. C++ Date and Time (tutorialspoint.com) (Go through this for more understanding)


E. Add a destructor to the program displaying a suitable msg.



Jun 04, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here