Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

check if number is negative javascript

Math.sign() has 5 possible return values:
1 // positive number
-1 // negative number
0 // positive zero
-0 // negative zero
NaN // not a number
 
PREVIOUS NEXT
Tagged: #check #number #negative #javascript
ADD COMMENT
Topic
Name
7+6 =