Last active
September 14, 2017 02:54
-
-
Save 92hackers/7f3c02c1f75909be29c0ea61cc55eb0d to your computer and use it in GitHub Desktop.
javascript number types
This file contains 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
const binary = 0b1111 | |
//=> 15 | |
const oct = 0o1111 | |
//=> 585 | |
const decimal = 1111 | |
// => 1111 | |
const hex = 0x1111 | |
// => 4369 | |
10..toString(2) | |
// => 1010 | |
// js support all kinds of number types. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment