DEV Community

Ratik Mahajan
Ratik Mahajan

Posted on

1

Java Oops Interview Question

what is compile time and run time polymorphism
Answer: compile time polymorphism is done at the compile time. example of the compile time polymorphism is method overloading and example of the run time polymorphism is method overriding.

what is inheritance in java.
inheriting the methods and properties from the parent class into base class is known as inheritance. extends keyword is used to inherit the state and behavior.

Top comments (0)

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay