Skip to main content

Questions tagged [modulo]

For questions about the modulo operator (usually denoted as "%"), which calculates the remainder of the division between two numbers.

10 votes
4 answers
3k views

By mathematical definition, for every nonnegative integer n and every positive integer d, it holds that the modulo ...
Dannyu NDos's user avatar
  • 1,485
8 votes
1 answer
855 views

Related to, but not the same question: Distinguishing modulo (Euclidean division) from remainder There are multiple ways a modulo operation can be performed. Most implementations, in C, for example, ...
CPlus's user avatar
  • 10.5k
14 votes
5 answers
2k views

The % operator in most programming language provide a remainder from integer division. When both operands are positive all works as expected. But when the number is ...
CPlus's user avatar
  • 10.5k