We can use ++
to increment
the value of a number by 1
.
In the example given above,
we declare the variable number
using the let
keyword
because the value of number
will be changed
when we perform number++
.
We can use --
to decrement
the value of a number by 1
.