18.The following program shows an error message due to accessing a private data of the base class by the public member function of the derived class via private inheritance. Because of the private...





18.The following program shows an error message due to accessing a private data of the base class by the public member function of the derived class via private inheritance. Because of the private derivation, the base class members cannot be accessed by the public members of the derived class.



19.The following program tries to access the private data of the base class by the public member function of the derived class via public inheritance through friendship.








May 18, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here