Question: #include using namespace std; class Date private: int day, month, year; public: Date() { day = 1; month = 1; year = 1990; } void

 #include using namespace std; class Date private: int day, month, year;
public: Date() { day = 1; month = 1; year = 1990;

#include using namespace std; class Date private: int day, month, year; public: Date() { day = 1; month = 1; year = 1990; } void Print() const { cout > Then it is a leap year else it is not a leap year (2) Define class Exam which has the following private member varlables: duration of type Integer length of the exam in minutes and date of type Date. (3) Write the default constructor for Exam which initializes the value of duration to 1. (4) Write a member function called Print, that prints all the details of Exam (Note:Don't use any getter member function). 15) Write a function called setterfint d, int m. inty. Int duration) to assign values to the data members in class Exam. (6) Define class Online Exam which has a private member varlable called sessionID of type Integer. This class inherits other attributes trom the Exam class using publle Inheritance 6.1. Write the default constructor of the class, which Initializes the session to 0. 6.2. Write the member function setterfint,intm, Inty, Int duration, Intld) that assigns values to all the data members in class Online Exam, 6.3. Write a Print member function to print all the details of an Online Exam. 17) In main function write the following: 7.1. Create an object named Exam Date of type Date and assign to it the date 19/2/2020. 7.2. Declare di as an Exam object. 7.3. Declare P1 as a polnter to an object of Type Online Exam 7.4. Create a dynamic array of length and store the address of the array in P1, 7.5. Read values from the user and assten them to the member variables of the objects in the previously created dynamic array 7.6. Call the Print member function to print the contents of the dynamic array 9.J. Check If the ExamDate is a leap year or not

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!