In my opinion 11 mod 7=4
and 11 mod -7=3
Are options of ques 1 number theory quiz-1 wrong?
hello @Ankit_kumar_3003
yeah first one is correct .
now for second ->
we can write
a= ( a/b ) *b + (a%b)
from above equation we get a%b= > a-(a/b) * b
a%b= a-(a/b) * b ||| note (a/b) here is integer division
put a=11 ,b=-7
11 %(-7) = 11 - (11/-7)*(-7)
. . . . = 11-(-1) * (-7)
. . . . = 11-(7)
. . . . = 4
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.