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
Explain what access modifiers can be used for methods?
How do you clear an arraylist in java?
Which class is used by server applications to obtain a port and listen for client requests?
Is string is a data type?
What is the difference between Java1.4 and Java1.5
What is the difference between abstract classes and interfaces?
What is difference between hashset and hashmap?
Explain about strings in java?
What is Hierarchy of exception?
What is difference between static and final?
What is numeric function?
What is arrays sort in java?
Which package is used for pattern matching with regular expressions?
How do you check if a character in a string is a digit or letter?
How do you get length in java?