Polymorphism

- Polymorphism means same name different behaviour in the polymorphism one mathod is used for perfoming various task.
- Due to which we get importent factor - Code Reusability.
- And the coplexity reduced.
Java impliments polymorphism By three ways.
- Method overloading
- Method overriding
- constructor overloading and overriding
Method Overloading
Condition required for method overloading
- All Methods are belong to same class
- Methods names are exactly same
- Either the number of parameters or type of parameters should be different
- Return type plays no role in method overloading
- method overloading also called
- Ststic Binding
- Early Binding
- Compile time polymorphism