Revature interview question

What is the difference between method overload and method overriding?

Interview Answer

Anonymous

10 Dec 2020

Overloading occurs when two or more methods in one class have the same method name but different parameters. Overriding means having two methods with the same method name and parameters Polymorphism applies to overriding, not to overloading. Overriding is a run-time concept while overloading is a compile-time concept.

6