= Solution
Use the standard convention that a <projective variety> is nonempty and irreducible, over an <algebraically closed field>. Let $f:X\to\mathbb A^1$ be a <regular function>, and compose with the inclusion into $\mathbb P^1$. Its graph is closed in $X\times\mathbb P^1$: on an affine open of $X$, with homogeneous target coordinates $[T_0:T_1]$, it is given by $T_1-f(x)T_0=0$. This equation has no solution at $T_0=0$, and the local closedness statements glue.
Embed $X$ as a closed subvariety of $\mathbb P^m$. The graph is then closed in $\mathbb P^m\times\mathbb P^1$. Part 1, after swapping factors, makes its projected image $f(X)$ closed in $\mathbb P^1$. Since it avoids infinity, it is a proper closed subset of the projective line and hence finite. A continuous image of an irreducible space is irreducible, and a nonempty finite closed subset over an algebraically closed field is irreducible only if it is a singleton. Hence
$$
\boxed{f\equiv\lambda\text{ for some }\lambda\in k,\qquad H^0(X,\mathcal O_X)=k.}
$$
This proves <global regular functions on an irreducible projective variety> are constant, using the closed-projection result rather than assuming it. If one allows disconnected projective algebraic sets instead of irreducible varieties, different components can carry different constants; irreducibility is the relevant convention here.
Back to article page