Javascript Math functions are useful for number calculus, for example:
In this code we can use floor from Math to reduce the decimal number to the next low whole number.
var n1 = 43.4
var n2 = Math.floor(n1)
console.log(n2) // Expect to be 43On the other hand, we can use cell to get the next up whole number from a float number.
var n1 = 43.6
var n2 = Math.ceil(n2)
console.log(n2) // Expect to be 44To get a random number we can use random method
var randomNumber = Math.random()
console.log(randomNumber) // random number