sameSign()

Determines if two or more numbers have the same sign (negative or positive).

This function is valid in v2.13.0 to v2.14.0. This function has been downloaded 25 times.

Parameters

{number} number1
First number to be compared to all of the other passed numbers.
{number} number2
Second number to be compared to all of the other numbers passed.
{…number=} numberX Optional
All additional numbers, if any, to be compared to number1.

Returns

{boolean}
Returns true if all of the numbers are positive or all of them are negative, otherwise false is returned.