Created
March 29, 2013 20:45
-
-
Save InPermutation/5273526 to your computer and use it in GitHub Desktop.
Negative zero is not actually identical to positive zero.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // [true, true, true]: | |
| [ | |
| 0 === -0, | |
| Math.atan2(0, -0) === Math.PI, | |
| Math.atan2(0, 0) === 0 | |
| ] | |
| // [false, false]: | |
| [ | |
| -0 < 0, | |
| 0 > -0 | |
| ] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
See http://es5.github.com/#x15.8.2.5 for explanation of the behavior of
Math.atan2