remainder method Null safety
- num other
The remainder of the truncating division of
r of this operation satisfies:
this == (this ~/ other) * other + r.
As a consequence, the remainder
r has the same sign as the divider
The result is an int, as described by int.remainder,
if both this number and
other are integers,
otherwise the result is a double.
print(5.remainder(3)); // 2 print(-5.remainder(3)); // -2 print(5.remainder(-3)); // 2 print(-5.remainder(-3)); // -2
num remainder(num other);