Can someone explain why the inverse $4$ modulo $9$ is $7$? What am I missing? $$9 = 2\cdot4 + 1$$ $$1 = 9-4\cdot2$$ $$1 = -2\cdot4 + 1\cdot9$$
Isn't then $-2$ inverse of $4$ modulo $9$?
Can someone explain why the inverse $4$ modulo $9$ is $7$? What am I missing? $$9 = 2\cdot4 + 1$$ $$1 = 9-4\cdot2$$ $$1 = -2\cdot4 + 1\cdot9$$
Isn't then $-2$ inverse of $4$ modulo $9$?
That is correct, but remember that $-2 \equiv 7 \pmod 9$.