How to calculate $3^{-1}$ modulo $2$ and modulo $3$?

63 Views Asked by At

I have to figure out these, but i dont know how:

$3^{-1}\equiv x \pmod{2}$

$3^{-1} \equiv y \pmod{3}$

For modulo $2$ my idea is that:

$1 \equiv 3 \pmod{2}$ divided by 3:
$3^{-1} \equiv 1 \pmod{2}$

But what about mod $3$?

1

There are 1 best solutions below

0
On

If you working to modulo $2$ then there are only two distinct values: $0$ and $1$. $3$ is congruent to $1$ so $1 / 3$ = $1 / 1$ = $1$.

In modulo $3$, $3$ = $0$ so $1 / 3$ is undefined.