Tracks
/
C#
C#
/
Syllabus
/
Method Overloading
Me

Method Overloading in C#

1 exercise

About Method Overloading

Method overloading allows multiple methods in the same class to have the same name. Overloaded methods must be different from each other by either:

  • The number of parameters
  • The type of the parameters

There is no method overloading based on the return type.

The compiler will automatically infer which overloaded method to call based on the number of parameters and their type.

Edit via GitHub The link opens in a new window or tab

Learn Method Overloading