Returns the remainder (floating-point) of x / y.
If the value of y is 0, fmod returns an indefinite by default.
Return value:
Returns the remainder (floating-point) of x / y.
Example
import standard.C.math
class Main {
function Main() {
var w = -10.0;
var x = 3.0;
var z;
z = fmod(w, x);
echo "The remainder of " + w + " / " + x + " is " + z + "\n";
}
}
Results
The remainder of -10 / 3 is -1