Function - Overloaded Function (Overloaded)

1 - About

Same function name but with a different signature (list of parameters)

Their will be then the same function name or an operator but that manipulates two different objects (data structure, type).

3 - Example

3.1 - Function / Method


declare function getWidget(n: number): Widget;
declare function getWidget(s: string): Widget[];

3.2 - Operator

built-in operators such as addition (+), can be:

  • integer addition
  • or floating-point addition.

The two operations work on different types of operands and require different functions.

4 - Documentation / Reference


Data Science
Data Analysis
Statistics
Data Science
Linear Algebra Mathematics
Trigonometry

Powered by ComboStrap