$\dim (D-P)=\dim (D)-1$ I'm trying to prove this question:

Let $D$ be a divisor in $F|K$ such that $\dim (D)\gt 0$ and $0 \neq
 f\in \mathscr L(D)$. Thus $f\notin \mathscr L(D-P)$ for almost all $P$.
   Then show that $$\dim (D-P)=\dim (D)-1$$ for almost all $P$.

I proved the first part of the question, but I couldn't prove $\dim (D-P)=\dim (D)-1$ using this first part.
Thanks 
Source: first chapter of Algebraic function fields and codes from Henning Stichtenoth
 A: Let $C$ be a curve over $k$, and $P$ a $k$-point.
Recall that we can think of $\mathcal{L}(D)$ as
$$\mathcal{L}(D)(U)=\left\{f\in K(F):\text{div}(f)\mid_U+D\mid_U\geqslant 0\right\}$$
Then, 
$$\mathcal{L}(D-P)(U)=\left\{f\in K(C):\text{div}(f)\mid_U+D\mid_U-P\mid_U\geqslant 0\right\}$$
So, I think you can see that $\mathcal{L}(D-P)$ is a subsheaf of $\mathcal{L}(D-P)$, whose global sections correspond to global sections of $\mathcal{L}(D)$ vanishing at $P$. So, in particular, for almost all $P$, $\Gamma(C,\mathcal{L}(D-P))\subsetneq\Gamma(C,\mathcal{L}(D))$. 
But, note that if we think of $\mathcal{L}(-p)$ as being the ideal sheaf of the closed subscheme $p\subseteq F$, then we have the exact sequence
$$0\to\mathcal{L}(-p)\to \mathcal{O}_C\to \mathcal{O}_p\to 0$$
Tensoring this with $\mathcal{L}(D)$ gives
$$0\to\mathcal{L}(D-P)\to\mathcal{L}\to \mathcal{L}(D)\otimes\mathcal{O}_p\to 0$$
Passing to global sections we get 
$$0\to\mathcal{L}(D-P)(C)\to\mathcal{L}(D)(C)\to k$$
Which tells you that $\dim\mathcal{L}(D-P)(C)$ is either $\dim\mathcal{L}(D)(C)$ or $\dim\mathcal{L}(D-P)(C)-1$. 
So, for almost all $P$, so that $\mathcal{L}(D-P)(C)\subsetneq\mathcal{L}(D)(C)$ you have the desired dimension.
A: A variant on Alex Youcis's answer, maybe more direct:
Suppose that $P$ is not one of the points of $D$, so that functions $f \in \mathcal L(D)$ can't have a pole at $P$.  Evaluation at $P$ gives a linear map
$L(D) \to k$, whose kernel is $L(D - P)$.  So either this map is the zero map,
and $L(D-P) = L(D)$, or this map is non-trivial functional, and then
$L(D-P)$ has dimension one less than $L(D)$.
The map is non-trivial precisely if there is at least one $f \in L(D)$ such that $f(P) \neq 0.$   Any non-zero $f \in L(D)$ has only finitely many zeroes, for almost all $P$, we can be sure that $f(P) \neq 0$ for at least one $f \in L(D)$ (assuming
that $L(D) \neq 0$.)

If $P$ is one of the points of $D$, then the argument is similar, except that instead of evaluating at $P$, you should take the coefficient of the degree $-n$ term of the Laurent expansion of $f$ at $P$, if $n$ is the multiplicity of $P$ in $D$. 
[Added: as Jyrki notes in comments, we can ignore this case anyway, since it only involves finitely many points $P$.]

The argument with sheaves that Alex Youcis gives abstracts this 
 argument with evaluation, or taking leading order coefficients, and has the advantage that you don't need to separate these cases (and of course many other
advantages, since it plugs into the whole sheaf-theory machinery).
