math.floor js
snippet in javascript

math.floor js

user6808

console.log(Math.floor(5.95));
// expected output: 5

console.log(Math.floor(5.05));
// expected output: 5

console.log(Math.floor(5));
// expected output: 5

console.log(Math.floor(-5.05));
// expected output: -6

floor in js

user9025

Input  : Math.floor(4.23)
Output : 4

Input  : Math.floor(0.8)
Output : 0

math.floor

user8486

console.log(Math.floor(5.05));
// expected output: 5

javascript floor

user3342

Math.floor(1.6);

result: 1