Let $X$ be an integral scheme, proper over an algebraically closed field $k$. It is known that $\Gamma(X,\mathcal{O}_X)=k$. In the book that I am reading, the author claims that this fact follows from the following fact:
If an integral affine scheme $\operatorname{Spec}A$ is proper over a field $k$, then $A$ is also a field, i.e. $\operatorname{Spec}A$ is a single point.
My question is, how do we use this fact to deduce that $\Gamma(X,\mathcal{O}_X)=k$? I have been pondering over this for awhile and am unable to get why. Any hints given would be greatly appreciated!
Any proper morphism is of finite type by definition, so $A$ is a field which is finitely generated as an algebra over $k$. By Zariski's lemma, any such field must be finitely generated as a module over $k$. Since $k$ is algebraically closed by assumption, we conclude $A = k$.