Friday, 21 December 2012

Inheritance(C++,Java and C#)

By on 03:47

The definition of Inheritance is quite simple means "When a class inherits some features/characteristics /property from another class then we called this situation as Inheritance ".Its come under the category of Reusability of Oops concept.This feature deals in many programming language like C++,java,C#(c sharp) etc.

The Class which inherits the features is called as child class or derived class or sub class.
The Class from which the feature is inherited are called parent class or super class or base class.

Type of Inheritance:-

1)Single Inheritance:-When 1 class(Class A) is inherits the features of another class(Class B).Example-

2)Multilevel Inheritance:-When a class(Class C) inherits form Class B which again inherits from Class A then this is called as Multilevel Inheritance.

3)Multiple Inheritance:-When single class(Class C) is inherits from two super class then inheritance is called as Multiple Inheritance.

4)Hierarchical Inheritance:-When more than one class(Class B,C,D) is inherit from single(Class A) parent class than the inheritance is called as Hierarchical Inheritance.

5)Hybrid Inheritance:-In this type of inheritance we used more than one type of inheritance in a single inheritance.

If you have any query then leave your comments and don't forgot to follow me on Google+,Facebook,Twitter.


  1. Hello I am Amit Meena,I want to know that is concept of Inheritance is same in c++,java and in C sharp.

  2. Hi Amit,Yeah the core concept of Inheritance is same(most of the time) in above mention programming

  3. Thank you so much Sudhir,its my pleasure to help you.


Related Posts Plugin for WordPress, Blogger...