Inheritance Java Interview Questions – Set 02

How can we implement polymorphism in Java ? Polymorphism is the capability of an action or method to do different things based on the object that it is acting upon. There are two types of polymorphism:- Method Polymorphism through overloading. Object polymorphism by inheritance / interfaces. What are the advantages of the model over the … Read more

Inheritance Java Interview Questions – Set 01

What are the alternatives to inheritance? Delegation is an alternative to inheritance. Delegation denotes that you include an instance of any class as an instance variable, and forward messages to the instance. It is safer than inheritance because it ceases you to think about forwarded message , because the instance is of a known class, … Read more

Inheritance Java Interview Questions

Inheritance Java Interview Questions – Set 02 Inheritance Java Interview Questions – Set 01