Top "Modulo" questions

The modulo (sometimes called modulus) operation finds the remainder of division of one number by another.

Modulus operation with negatives values - weird thing?

Can you please tell me how much is (-2) % 5? According to my Python interpreter is 3, but do you have a …

python math modulo
gcc gives error while using fmod()

Sample code for fmod: #include <stdio.h> #include <math.h> int main(void) { double x = 0.14527, y = 3.14159; …

c gcc ld modulo libm
How can I get alternate styling in <ItemTemplate> (.NET)?

I'm using EPiServer for this website. Unlike asp:DataList, EPiServer:PAgeList does not have AlternatingItemTemplate. So I need to create …

.net css repeater modulo itemtemplate
Alternative to using % operator and / Operator in C++

It is told that modulo operator "%" and divide operator "/" are very inefficient in embedded C++. How can I alternatively achieve …

c++ modulo processing-efficiency
How to calculate modulo of negative integers in JavaScript?

I'm trying to iterate over an array of jQuery objects, by incrementing or decrementing by 1. So, for the decrementing part, …

javascript jquery math modulo negative-number
Modulo of long long int number

Hi i tried out a code in c and considering that all variables in the following line of code were …

c modulo unsigned-long-long-int
How to correctly use Mod 10^9+7

In Java, I need to calculate sum of squares of first n numbers i.e. 1^2 + 2^2+ 3^2+.....+n^2 which is n(n+1)(2…

java algorithm modulo largenumber
Python-style integer division & modulus in C

In Python and Ruby, signed integer division truncates towards negative infinity, and signed integer modulus has the same sign the …

java c++ c modulo division
VbScript validate IBAN with mod97 (number is too big)

So I am writing an application in VbScript and I am trying to validate an IBAN number. The problem though, …

vbscript modulo iban
The modulo operator (%) gives a different result for different .NET versions in C#

I am encrypting the user's input for generating a string for password. But a line of code gives different results …

c# .net modulo