Negate | MATH_NEGATE

Syntax

MATH_NEGATE( [value] )

Parameters

value
A number to negate. If the value is not a NUMBER, the FLOAT operation will be used to convert it.

Return Value

Returns a number.

Description

Get the negative value of a number.

Examples

MATH_NEGATE(1) # returns -1
MATH_NEGATE(null) # returns 0
MATH_NEGATE("-15") # returns 15