A proof of the equivalent way :
If $\;u\colon A^n\longrightarrow A^n$ is surjective, $u$ is injective.
Indeed, consider the short exact sequence:
$$0\longrightarrow K \overset{i}\longrightarrow A^n\overset{u}\longrightarrow A^n\longrightarrow 0,$$
where $i$ is the canonical injection of $K=\ker u$. This is a split exact sequence, since the last term is free, so $i$ has a linear retraction, which is surjective. In other words, $K$ is a finitely generated submodule of $A^n$.
Tensoring with each of the residual fields $\kappa(\mathfrak m)=A_\mathfrak m/\mathfrak mA_\mathfrak m$, $\;u\otimes_A\kappa(\mathfrak m)\colon\kappa(\mathfrak m)^n\longrightarrow \kappa(\mathfrak m)^n$ is an automorphism, hence the image of $K\otimes_A\kappa(\mathfrak m)$ in $\kappa(\mathfrak m)^n$ is $0$.
We conclude that $K_\mathfrak m=\{0\}$ for each maximal ideal, whence $K=\{0\}$ since $K$ is finitely generated.