Skip to content

multiply

The multiply() method multiplies two numbers together. It can be used in a curried mode to create partially applied multiplication functions.

Interactive example

Syntax

Classic signature

typescript
function multiply<
	GenericInput extends number
>(
	input: GenericInput,
	operand: number
): number

Curried signature

typescript
function multiply<
	GenericInput extends number
>(
	operand: number
): (input: GenericInput) => number

Parameters

  • input: The number to multiply (multiplicand, classic signature only).
  • operand: The multiplier.

Return value

returns the product of the two numbers (input * operand).

See also

Sources

Released under the MIT license.