why java does not support multiple inheritance

Answer Posted / sskur

To say why java doesn't support inheritance directly like c++
should be the diamond problem faced by c++,

(Diamond problem is an ambiguity that arises when two
classes B and C inherit from A, and class D inherits from
both B and C. If a method in D calls a method defined in A
(and does not override it), and B and C have overridden that
method differently, then via which class does it inherit: B,
or C?)

Is This Answer Correct ?    206 Yes 22 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is difference between static class and normal class?

787


How do you find the independent variable?

767


How do you use parseint in java?

752


What is :: operator in java?

734


What is the common usage of serialization?

836


What is variable and constant explain with example?

792


What is the association?

780


Assume a thread has lock on it, calling sleep() method on that thread will release the lock?

897


Is oracle java 11 free?

732


Why static functions are used?

831


What is backdrop?

831


What is anti pattern in cyber security?

766


Why do we need data structure in java?

835


What is double data type?

761


what are the disadvantages of indexes in oracle?

2118