With a prime number p and a not equal to 0, how can I prove that there exists an integer b such that ab is congruent to 1 (mod p)?
What I have done so far is I know that the GCD(p,a) is either 1 if p does not divide a or it is p if p does divide a. I am able to take GCD(p,a) = 1 to the end by using the fact that ab + pk = 1 and manipulating that to show that ab is congruent to 1 (mod p), but am stuck on how to move forward if the GCD(p,a) = p and p divides a.