Find the remainder left when 1 9 6 + 2 9 6 + 3 9 6 + . . . . + 9 6 9 6 is divided by 9 7
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Exactly. :)
Cant we use any other theorem here??
Log in to reply
I can't think of anything else. Do you have something in mind?
Log in to reply
You can use Euler's Theorem, which is a generalization of Fermat's Little Theorem.
Log in to reply
@Joanne Lee – But that's basically the same thing. Note that ϕ ( 9 7 ) = 9 6 and we're back to Fermat's Little Theorem.
Nice solution :)
Python code:
s=0
for i in range(96):
a=i+1
for j in range(96):
a=a%97
if j==93:
a=a
else:
a=a*(i+1)
s=s+a
print s%97
Worst solution ever !!!
I also wanna learn that phython
Super maccha :)
By Fermat's little theorem, we know that a 9 6 mod 9 7 ≡ 1. Therefore 1 9 6 + 2 9 6 + 3 9 6 + . . . + 9 6 9 6 mod 9 7 ≡ 96.
Java Code;
Sorry, I dont know how to create this code block.
Problem Loading...
Note Loading...
Set Loading...
Fermat's little theorem .
Fermat's little theorem tells us that if g cd ( a , p ) = 1 , then a p − 1 ≡ 1 ( m o d p ) [the p here is a prime number].
So, 1 9 6 + 2 9 6 + 3 9 6 + ⋯ + 9 6 9 6 ≡ 1 + 1 + 1 + ⋯ 1 ≡ 9 6 ( m o d 9 7 ) .
And our answer is 9 6 .