why java does compile time polymorphism at run time ?
Answer Posted / sarbbottam bandyopadhyay
compile time polymorphism is nothing but dynamic binding.
For overloaded method java uses static binding.
For overridden method Java uses dynamic binding.
Weather the method of the base class or the method of parent class will get invoked depend on the method invocation. i.e. which object is invoking the method, which class this object is an instance of.
Refer the below link.
http://download.oracle.com/javase/tutorial/java/IandI/polymorphism.html
| Is This Answer Correct ? | 5 Yes | 16 No |
Post New Answer View All Answers
How do you replace all in word?
What is the purpose of the system class in java?
What is Gang of four design patterns
What is int lol?
What is java used for?
How to convert string to char and vice versa?
How the interruptible method gets implemented?
What is a newline character in java?
What is a line break example?
What are the properties of thread?
What are the different types of constructor?
What is the difference between static class and normal class?
Is the empty set a singleton?
Can classes declared using the abstract keyword cab be instantiated?
Why bytecode is called bytecode?