(a) What is a copy constructor ? What are the advantages of a copy co…

Previous year question for Object Oriented Programming Using C++.

Question

(a) What is a copy constructor ? What are the advantages of a copy constructor ? Give examples.

(b) Write a class employee with two functions get data and put data to read the name and number of employees and display them respectively. Drive two classes one manager and other scientist. In manager class add one more variable title. In scientist class add more variable publication and display them.

Related pages

More PYQs on Constructor and Destructor Functions

Open on CachedInfo