I have a little question to ask. I need to have an defitinition of what mean Inheritance and to have an example. I have the book of C ++ but do not have any proper expanation
chera
0
Newbie Poster
Recommended Answers
Jump to PostPut simply, inheritance is saying that one class is a part of another class.:
class A { public: void foo() { cout<<"foo\n"; } }; class B: public A {};
You can create an object of B and call foo because A is a part of B. B …
All 2 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.