I'm following Beauville's book "Complex Algebraic Surfaces".
If $S$ is a K3 surface and $C$ is a smooth not hyperelliptic curve of genus g, then we have a birational morphism $\phi : S\rightarrow\mathbb{P}^g$, whose restriction to $C$ is the canonical morphism $C\rightarrow\mathbb{P}^{g-1}$. Since $S$ is minimal, it is isomorphic to the surface $\phi(S)$. The hyperplane sections of $\phi(S)$ are the curves $H=\phi( C^\prime)$, with $C^\prime\in|C|$.
$H^2=C^2=2g-2$.
We have the exact sequence $$0 \rightarrow I \rightarrow \mathcal{O}_{\mathbb{P^g}}\rightarrow\mathcal{O}_{\phi(S)}\rightarrow 0,$$ where $I$ is the ideal sheaf of $\phi(S)\subset\mathbb{P}^g$.
From this we obtain also the exact sequence $$0\rightarrow I(k)\rightarrow\mathcal{O}_{\mathbb{P}^g}(k)\rightarrow\mathcal{O}_{\phi(S)}(k)\rightarrow 0,$$ where $I(k)$ is the sheaf of polynomials of degree $k$ that vanish on $\phi(S)$.
Using the cohomology sequence we have $$h^0(\mathcal{O}_{\mathbb{P}^g}(k))\leq h^0(I(k))+h^0(\mathcal{O}_{\phi(S)}(k)).$$
If $g=4$, $\phi(S)$ has degree $6$ and we have $$h^0(\mathcal{O}_{\mathbb{P}^4}(2))=15\,\,\,and\,\,\,h^0(\mathcal{O}_{\phi(S)}(2H))=14,$$
so $\phi(S)$ is contained in a quadric of $\mathbb{P}^4$. Repeating the same argument with $k=3$, we obtain that $\phi(S)$ is contained also in a cubic. Beauville then claims that $\phi(S)$ is a complete intersection surface $S_{2,3}\subset\mathbb{P}^4$. And i agree since they both have the same degree and $S_{2,3}$ is a K3 surface, but i think that maybe this is not enough as we see in the next example.
He repeats the same argument with $g=5$ and he finds out that $\phi(S)$ it is contained in 3 quadrics that are linear independent in $\mathbb{P}^5$. This time he can't conclude that $\phi(S)$ is a complete intersection $S_{2,2,2}\subset\mathbb{P}^5$. Infact in this case, if $C$ admits a $g^1_3$ (i.e. an invertible sheaf $L$ of degree 3 such that $h^0(C,L)=2$), then $\phi(S)$ is not a complete intersection $S_{2,2,2}$ (exercise 11 of the same section of the book). But i see no difference with the $g=4$ case, infact $S_{2,2,2}$ is a K3 surface of degree $8$, like $\phi(S)$.
I don't understand why in the case $g=4$ he can conclude all at once that $\phi(S)$ is a complete intersection $S_{2,3}$, since in the second case he can't.