+ 1
How to use floor division in js?
Everytime I use (//) for floor division it takes the line as a comment, what do I do?
4 Answers
+ 4
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/floor
JavaScript has a math library that takes care of that.
You can also OR the number to 0, but, although rare, it does ciel instead
+ 2
do you want to apply division?
+ 2
Yup floor division.
Means only quotient