Hierarchical inheritance definition with example in C#.Net

Hierarchical inheritance

This is one type of inheritance, where we will have one or more derived classes are derived from one base class. Clearly, it is like tree structure.

Example:

class BaseClass{
//this is base class
}

class DerivedClass1:BaseClass{
//this is inherited by BaseClass
}

class DerivedClass2:BaseClass{
//this is inherited by BaseClass
}

Diagram:
Hierarchical inheritance definition with example in C#.Net


See more OOPS DOTNET Interview Questions

See more ASP.NET, C#.NET, SQL Server and more Interview Questions


Share this post :

Featured post

JQuery Tutorial 1- Introduction to JQuery

If you have any queries or suggestions, please feel free to ask in comments section.

 
Support : Ranga Rajesh Kumar
Copyright © 2012. ASP.NET Examples - All Rights Reserved
Site Designed by Ranga Rajesh Kumar