I am having trouble comprehending the following problem:
In mod $n$ arithmetic, the quotient of two numbers $r$ and $m$ is a number $q$ such that $mq = r$ mod $n$. (The author mentioned before that he represents $\equiv$ with $=$). Given $r$, $m$, and $n$, how can you find $q$? How many $q$'s are there? Under what conditions is $q$ unique? [Hint: $mq = r$ mod $n$ iff there is an integer $k$ such that $qm + kn = r$. Divide by gcd($m$, $n$).
To find $q$, I think we need to first calculate gcd($m$, $n$) and then perform extended Euclid algorithm.
I'm not sure about the second question regarding how many $q$'s there are.
For the third question, I think $q$ is only unique if $m$ and $n$ are relatively prime.
I scoured the textbook for some hint, but I just have trouble understanding and I am not confident in my answers. A clear explanation of the problem and/or solutions is much appreciated.