Remainder when 110! Is divided by 107^2 (107 square)?
Answers
Answered by
6
Hi.
There is this Wilson formula that you should look up. I will explain it first with an example or two.
Eg.1: 2! mod 3 = 2
Eg.2: 4! mod 5 = 4
Eg.3: 6! mod 7 = 6
Where 'mod' simply means 'remainder', unlike the standard division operator '/' that would give 2!/3=0 or 6!/7=102.
If you haven't yet noticed a pattern in the example, it is simply:
(n-1)! mod n! = n-1 where n is a prime number.
Note that the above can also be written as:
(n-1)! mod n! = -1.
Unlike positive remainders, a negative remainder is used for mathematical simplicity in solving questions and it means that the actual remainder (in this case) is = n-1. (If it was -2 then it means it is n-2)
Coming to our question,
110! mod 107^2
= 107 * 106! * 108 * 109 * 110 mod 107^2
= 107 * ( 106! * 108 * 109 * 110 mod 107)
= 107 * (-1 * 1 * 2 * 3)
= -642
Therefore the remainder is 107^2 - 642 = 10807.
Note that -1, 1, 2, 3 are the remainders of 106!, 108, 109, 110 when divided by 107.
Cheers!
Similar questions