What is multiple inheritance & can we implement it in java?

Answer Posted / lavanya

Java Does Support Multiple inheritance through the usage of
intrface concept. multiple inheritence is one class
acquiring the features of more than one class.

Java can extend one class but can implement more than one
interface.

intreface is a class whose methods are declared but
functionality not defined. The implementing class has to
define that functionality.

Through the use of interfaces we can avoid the confusion of
which class to use in case two extended classes have same method

Is This Answer Correct ?    13 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is class forname reflection?

514


Why java uses the concept of the string literal?

543


What is runtime polymorphism or dynamic method dispatch?

520


Can long be null in java?

540


What are advantages of using Java?s layout managers than windowing systems?

1851






How use .contains in java?

617


What is a wrapper method?

531


Say any two properties in beans?

632


Will the compiler creates a default constructor if I have a parameterized constructor in the class?

579


What is static variable with example?

557


How do you sort a set in java?

514


Can we have a try block without catch block?

565


what is heap memory?

654


Give me example of derived data types.

587


Can we use return in constructor?

489