# Global sections of the projective space

Let $k$ be an algebraically closed field, and let $\mathbb{P}^n_k=\operatorname{Proj}(k[x_0,x_1,\dots,x_n])$, with structure sheaf $\mathcal{O}$. I would like to know how to prove that $\mathcal{O}(\mathbb{P}^n_k)\simeq k$.

Should I follow the proof in the case of varieties? Or the definition of the structure sheaf $\mathcal{O}$ makes this easier?

I tried to think of a global section $s\in\mathcal{O}(\mathbb{P}^n_k)$, consider it locally on the $D_+(f)$, then it should turn out that requiring the compatibility on intersections $s$ should be constant and an element of $k$. I have problems to rephrase this in commutative algebra terms. Can anyone help me on this? Or is this procedure not enough?

Cover $\mathbb{P}^n_k$ with $D_+(x_i)$, and then use the sheaf SES
$$0\to\mathcal{O}_{\mathbb{P}^n_k}(\mathbb{P}^n_k)\to \prod_\ell\mathcal{O}_{\mathbb{P}^n_k}(D_+(x_\ell))\to\prod_{i,j}\mathcal{O}_{\mathbb{P}^n_k}\left(D_+(x_i)\cap D_+(x_j)\right)$$
$$s\mapsto s\mid_{D_+(x_i)}\quad\quad (s_\ell)\mapsto (s_i\mid_{D_+(x_j)\cap D_+(x_j)}-s_j\mid_{D_+(x_i)\cap D_+(x_j)})$$
With this very explicit cover, you should be able to find that the global sections are just $k$!