Modular division

Can anyone please teach me how to calculate modular division (a/b)%m if both a and b are large and both are formed as a result of multiplication of numbers

@anshuman_U,

(a/b)%m = ((a % m) * (Inverse_modulo(b) % m)) % m
Where Inverse_modulo(b) = ((b ^ (m - 1)) % m)

You can calculate Inverse_modulo by modular exponentiation.

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.