protected inheritance and abstract classesView more random threads:
- info regarding "source file not compiled"
- how can i mail you the snapshot of compiled files.in C++...
- some features of PREPROCESSOR in c and C++
- is the dot operator connect the class object and a member...
- PROBLOM IN PROGRAMMING code 2011
- In aggregation we use a pointer e.g. like chair object in a...
- program Output in C++ 2012
- What is the concept of having the data member of the same...
- what is Topic base content management system? How it looks...
- read int size (is that true )in bytes 2 and short int bytes...
Example
Code:class Parent{ int id; char * name; public: virtual void display()=0; }; class Derived:protected Parent { public: void display(){ cout<<"Derived class"<<endl; } }; int main(){ Derived obj; obj.display(); system("pause");
Sponsored Links
There are currently 1 users browsing this thread. (0 members and 1 guests)