all are saying java doesn't support multiple inheritance but
by default Object class is super class for all the user
defined classes and we can extend atmost one class so each
class can extend more than one class so java supports
multiple inheritance?i am confused with this,pls any one
Answers were Sorted based on User's Feedback
logic is simple differnet
imagine you create a class
ya this class extends Object class implicitly
and it will definitely call the Object class constructor
but if you extends the Class A explicitly
then what will happen
class A extends AO
so what happen because the Object class Replace by this
immediate super class which is in your Apis which you build
in your project
now the class AO is responsible to implicit extends Object
so what is the mean that Object inheritence is passeddown
through your Immediate super class
so don't say that implicit inheritence creete the mulitiple
"because in java is not allowed beacaus so ambiguity
when one class extends Two classes and both have same method
then which method will call
|Is This Answer Correct ?||13 Yes||0 No|
Answer / biswajit singh
I completely agree with Amit Singh. Excellent example.
|Is This Answer Correct ?||2 Yes||0 No|
Answer / kartik naidhruva
Its foolish to say a class extends more than one class...
Who told u that!!!!
inorder to implement multiple inheritance in java we use
with the help of interfaces we can Partially implement
|Is This Answer Correct ?||2 Yes||6 No|
What is the GregorianCalendar class?
What is a static method in java?
What restrictions are placed on method overriding?
What is backdrop?
Explain naming conventions for packages?
write a program to create an arraylist with string(add,remove) operation.and value should be enter through keyboard.
What is vector capacity in java?
When do we use synchronized blocks and advantages of using synchronized blocks?
What is the difference between yielding and sleeping?
Which is not Object in Java?
Which of these methods belong to Thread & Object class? join, yield, sleep, wait, notify
Explain about strings in java?