# Another way to solve Number Theory Day 3 Challenge Explanation (3 of 4) example question

• Module 5 Week 1 Day 3 Challenge Part 3 Mini-Question

71 is 1 mod 7
72 is 2 mod 7
73 is 3 mod 7
74 is -3 mod 7
75 is -2 mod 7
76 is -1 mod 7
so -3 * -2 * -1 * 1 * 2 * 3 mod 7
is -36 mod 7 therefore the answer is 7*(-6)+6 = 6

• Please feel free to share other ways to do this problem.

• I really love the symmetry here!

This is a great way! And the minus signs all cancel out very nicely.

You asked for another way, and here is a slightly different way which really isn't all that different from the original method, but it simplifies some of the intermediate calculation a little bit. You can multiply the first few together, and then find the remainder of that product at each step before multiplying the other numbers.

$$71 \text{ is } 1 \text{ mod } 7$$

$$72 \text{ is } 2 \text{ mod } 7$$

$$73 \text{ is } 3 \text{ mod } 7$$

$$\rightarrow 71 \times 72 \times 73 = 1 \times 2 \times 3 = \textcolor{red}{-1 \text{ mod } 7}$$

Now, let's multiply the other numbers!

$$74 \text{ is } 4 \text{ mod } 7$$

$$\rightarrow \textcolor{blue}{ 71 \times 72 \times 73 \times 74 } = -1 \times 4 = -4 = -4 + 7 = \textcolor{red}{3 \text{ mod } 7}$$

Now let's multiply the $$75.$$

$$75 \text{ is } 5 \text{ mod } 7$$

$$\rightarrow \textcolor{blue}{71 \times 72 \times 73 \times 74 \times 75} = 3 \times 5 = 14 + 1 = \textcolor{red}{1 \text{ mod } 7}$$

And finally, we've got the $$76.$$

$$76 \text{ is } 6 \text{ mod } 7$$

$$( 1 \text{ mod } 7 ) (6 \text{ mod } 7 ) = \boxed{ \textcolor{red}{6 \text{ mod } 7 }}.$$

This way, your "running total of your remainder" is always less than $$7,$$ so there are just smaller numbers to deal with. The are so many little shortcuts to calculating this, and it's kind of like a puzzle to find them!