Run Code
|
API
|
Code Wall
|
Users
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Blog
base base
//g++ 5.4.0 #include <iostream> using namespace std; class base{ public:void basefun(){cout<<"frm base"<<endl; } }; class derr:public base{ public:void basefun(){cout<<"frm derr"<<endl; }}; void somefunc(base *baseobj){ baseobj->basefun(); } int main() { base baseobject; somefunc(&baseobject); derr derrobject; somefunc(&derrobject); }
run
|
edit
|
history
|
help
0
Please
log in
to post a comment.
¡Arriba, Papalotes, Arriba!
C++ Car Racing game framework
Dar
The Menu
E. Bus Number
Sorting sort function stl in c++
Count edges in a graph
Treap for spoj : MEANARR (we can use policy based data structures instead)
subset sum=k(dp)
Newspaper
stackse - search stackoverflow differently
Please log in to post a comment.