I am having trouble relating the two definitions of $(\mathbb Z/n\mathbb Z)^\times$, the collection of residue classes having a multiplicative inverse in $(\mathbb Z/n\mathbb Z)$; and apparently, $(\mathbb Z/n\mathbb Z)^\times$ is a pretty important subset of $(\mathbb Z/n\mathbb Z)$ (please don't tell me what it is though, I'd like to know it myself!)
The "standard" definition (so-to-speak) goes something like this: $(\mathbb Z/n\mathbb Z)^\times=\{ \bar{a}\in\mathbb Z/n\mathbb Z : \exists \bar{c}\in \mathbb Z/n\mathbb Z ~\text{ where } \bar a . \bar c=\bar 1\}$ The other one, the one that I am having trouble with, is this: $(\mathbb Z/n\mathbb Z)^\times=\{ \bar{a}\in\mathbb Z/n\mathbb Z : \gcd(a,n)=1\}$
So how come that these two things are the same? Even more so, how do I prove that these two definitions are the same thing?
Any help is much Appreciated,
Thanks in advance!