JavaScript Number Type

Creation

We can create new number instances by writing them straight out without any wrapping characters.

const year = 2020

This is essentially the same as the code below.

const year = new Number(2020)

Number notation

const int = 345
const float = 345.00
const scientific = 3.45e2
const hex = 0x159
const binary = 0b101011001