* Public, protected and private are three access specifiers in C++.
* Public data members and member functions are accessible outside the class.
* Protected data members and member functions are only available to derived classes.
* Private data members and member functions can't be accessed outside the class.
However there is an exception can be using friend classes.
* Public data members and member functions are accessible outside the class.
* Protected data members and member functions are only available to derived classes.
* Private data members and member functions can't be accessed outside the class.
However there is an exception can be using friend classes.
01:17
AtoZ C++ Interview Questions, AtoZ CPP Objective Type Questions, AtoZ C++ Study Material
0 comments:
Post a Comment