SIGN function

SIGN(Number) SIGN(Number)

Number

Number or { Number }

The number to test.

Returns

Number or { Number }

0, -1 or 1.

Returns 0 if a number is zero, -1 if it is negative and 1 if it is positive.

Examples

SIGN(-40)SIGN(-40)

Returns -1.

SIGN(40)SIGN(40)

Returns 1.

SIGN(0)SIGN(0)

Returns 0.

SIGN(BLANK())SIGN(BLANK())

Returns 0.