E
E
EvgenySManko2015-10-14 18:45:47
Mathematics
EvgenySManko, 2015-10-14 18:45:47

What does "modulo m" mean?

Hello.
There is a task that is basically clear:

Let's call the value of the expression 2^2^n the nth superpower of the number 2. Thus, for example, the third superpower of the number 2 is 2^2^3 = 2^8 = 256.
Your task is to calculate the nth superpower of two modulo m.

But the last sentence is not clear - what does "modulo m" mean?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
Alexander Oparin, 2015-10-14
@EvgenySManko

https://ru.wikipedia.org/wiki/%D0%A1%D1%80%D0%B0%D...
"modulo m" is about the same as "remainder of division by m"

B
bromzh, 2015-10-14
@bromzh

Remainder of the division. In general, this is done at school, the elementary foundations of number theory.

P
palandlom, 2022-02-06
@palandlom

Here it was "kosherly inflated"
https://brestprog.by/topics/modulo/
In some tasks there is a condition of the following form: “print the remainder of dividing the answer by 1000000007” or “print the answer modulo 1000000007”. This does not mean that you need to calculate the answer in the usual way and output ans % 1000000007. The answer in such problems is often so huge that it is difficult to represent it even with long arithmetic. To solve them, you need to make changes to all intermediate calculations so as not to go beyond the boundaries of the integer type.
We can say that in such problems we operate not with numbers, but with their remainders after division by 1000000007. This is possible due to the following properties of calculations with a remainder:
(a+b)modm=((amodm)+(bmodm))modm(a−b)modm=((amodm)−(bmodm))modm(ab)modm=((amodm)∗(bmodm))
modm Thus, we can perform the three most important mathematical operations, even without knowing the exact values ​​​​of numbers, only their remainders after dividing by a given number (modulus). Division is a separate topic, which we will discuss later.
Without delving into the definitions of terms from higher mathematics, operations with remainders from division by a modulo are called operations in a modulo field, and the remainders themselves are modulo numbers.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question