Java does not support multiple inheritance.
how interface helps in the same?
Answer Posted / sushila sonare
in java only one super class should be there. If we are
saying multiple inheritance there is more then one super
class and at time of object creation super(){super calling
statement} statement is invoked and control goes to super
class but if we are saying multiple inheritance then there
is more than one super class so JVM getting confused,
control goes to where. So avoiding this confusion only
single inheritance are allowed in JAVA you can use this
concepts in multiple levels.
In interface compiler is not keeping default constructor, so
there is no constructor chain. Thats why we can have
multiple interface at same level.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is singleton class example?
Tell us something about an iterator.
What is an example of procedure?
What is a method vs function?
Which is faster call by value or call by reference?
What is the exact difference in between Unicast and Multicast object? Where will it be used?
Do extraneous variables affect validity?
Is java ee a framework?
Why hashset is used in java?
Is array synchronized in java?
What is literal example?
Explain garbage collection in java?
What is the difference between static and global variables and also define what are volatile variables?
What is the meaning of variable in research?
Why do we use regex?