View the step-by-step solution to:

Assignment Introduction: Task Description: You have been hired as Programmer in a Software Development Company XYZ. Company asks you to develop...

Assignment

Introduction:

Task Description:

You have been hired as Programmer in a Software Development Company XYZ. Company asks you to develop Health Management System of a Hospital. At the moment you are required to develop the system with following functionalities.

Patient Registration
Doctors Registration
Billing for Patient

Detailed Description:


Assignment

Write a C++ program in which you are required to define a class named Citizen. The class must include the following two data members.

// data member for Citizen Name
1: Name

//data member for Citizen Nationality
2: Nationality

Your Program should define three constructors for the class Citizen

1: a constructor with no parameter
2: a constructor with two parameters (name, nationality)
3: a copy constructor

All of these three constructors are meant to initialize their respective objects. Incase of copy constructor, you are required to assign a separate space for the data members of the new object while copying the values of previously existed object.

Declare three objects (1 for each type of constructor) in main.

Write a function in class Citizen to display the initialized data members for each object.

Also write destructor for the class Citizen. Display a message that says “destructor called” in the destructor body.

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

-

Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question