Why does java doesnot support multiple inheritance?
Answer Posted / rathnakar
--> Java follows Super Class Object and Sub Class reference
at runtime to excute inherited and overridden methods.
--> Java doesnot support multiple inheritence by using
classes.becoz java compiler gets ambiguity if one method
is defined in many child classes. this happens due to
above reason
--> so execution fails . but it can be achieved using
interfaces. becoz it method over riding and every child
class is identified uniquely w.rt to interface.
Is This Answer Correct ? | 8 Yes | 0 No |
Post New Answer View All Answers
In how many ways we can create threads in java?
What is bufferedwriter?
What are the pillars of java?
What an i/o filter?
What is java life cycle?
What is the maximum size of a string in java?
why using interface interface ?
What is void in java?
How will you reverse a link list without using recursion?
Can an anonymous class be declared as implementing an interface and extending a class in java programming?
Can we override singleton class?
What is getclass () getname () in java?
Which programming language is most secure?
What about static nested classes in java?
Why vector is used in java?