Home > typescript-from-zero > avg

avg() function

Calculate the average of three numbers

Signature:

export declare function avg(a: number, b: number, c: number): number;

Parameters

Parameter Type Description
a number first number
b number second number
c number third number

Returns:

number