protected inheritance and abstract classesView more random threads:
- need some guidece for those students those are new in...
- AVL tree, It must satisfie the 2 conditions.
- how i can leave spaces between my program output
- Constructor for Composition of inherited classin c++ 2011
- PROBLOM IN PROGRAMMING code 2011
- Explain the difference between state and attribute in c++...
- Argc(argument count) and argv(argument value) are used in...
- What is difference among main() int main() void...
- Vector of stucts in c++ 2011-12
- Please define design recipe in C++?
Sponsored Links
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");
There are currently 1 users browsing this thread. (0 members and 1 guests)