Question: Using C++, write a simple program that does the following Create a class named Doctor that has three member variables: name - A string that
Using C++, write a simple program that does the following
Create a class named Doctor that has three member variables: name - A string that stores the name of the doctor num Patients - An integer that tracks how many patients the doctor must trea patient List - A dynamic array of strings used to store the patient names Write appropriate constructor(s), mutator, and accessor methods for the class along with the following: A method that inputs all values from the user, including the list of patient names. Note that this method has to support input for an arbitrary number of patient. A method that outputs the name and list of all patients.A method that resets the number of patient to 0 and the patient List to an empty list. An overloaded assignment operator that correctly makes a new copy of the list of patients.A destructor that releases all memory that has been allocated. Write a main method that tests (i.e., unit testing) all of your functions
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
