Policies & Guidelines

SIGN

Return sign of a number

Description

Returns -1 if the parameter is a negative number, 1 if it is positive, and 0 if it is zero. Returns null if it's not a number.

Function signature

SIGN(number: Number) => Number

Parameter

Description

Number

Number to check

Examples

Formula

Return value

SIGN(4)

1

SIGN(-4)

-1

SIGN(0)

0