Коэффициент JS
var floatingPointPart = (18/7) % 1;
var integerPart = Math.floor(18/7);
Fantastic Ferret
var floatingPointPart = (18/7) % 1;
var integerPart = Math.floor(18/7);
// find quotient in javascript
// The Math.trunc() function returns the integer part of a number by removing any fractional digits.
console.log(Math.trunc(10/3));
// expected output: 3
console.log(Math.trunc(12/5));
// expected output: 2
console.log(Math.trunc(12.3/7));
// expected output: 1
console.log(Math.trunc(-10/3));
// expected output: -3