Skip to content

Commit 90cadba

Browse files
committed
Math.floor & Math.random practice
1 parent d8c4077 commit 90cadba

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

‎Sprint-2/Prep/functions.js‎

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,14 @@ const changeNumber = luckyNumber.padStart(5, "0")
3434
console.log(changeNumber)
3535

3636
const anotherNumber = luckyNumber.padEnd(5, "0")
37-
console.log(anotherNumber)
37+
console.log(anotherNumber)
38+
39+
const carPrice = 30000.50
40+
const updatedCarPrice = Math.floor(carPrice)
41+
console.log(updatedCarPrice)
42+
43+
const addNumber = 20
44+
const addNumber2 = 30
45+
const addNumber3 = addNumber + addNumber2
46+
const addNumberResult = Math.random() * addNumber3
47+
console.log(addNumberResult)

0 commit comments

Comments
 (0)