From the definition, it says that Let $\displaystyle m\in\mathbb{Z^{+}}$ and $\displaystyle a\in\mathbb{Z}$. An integer $\displaystyle \overline{a}$ such that $\displaystyle \overline{a}a\equiv1\quad(mod\; m) $ is an Inverse of $\displaystyle a\; mod\; m$

From how I interpret it, it is...

$\displaystyle a\; mod\; m\;= $Remainder of $\displaystyle a\div m $

Inverse of $\displaystyle a\; mod\; m\;=a-m\cdot k$, where $\displaystyle k\in\mathbb{Z}$. Is this right?

So if I have $\displaystyle 3\; mod\;5$, The normal $\displaystyle 3\; mod\;5=3$. Inverse $\displaystyle 3\; mod\;5=-2$

Then it says that $\displaystyle \overline{a}a\equiv1\quad(mod\; m)$, does it mean $\displaystyle -2\cdot3\equiv1\quad(mod\; m)$ and so when $\displaystyle (-2\times3)\div3$, the remainder is 1? But it doesn't look like it.

I am very confused with the notation and how this whole inverse of modulus work.