This problem is Exercise II.2.3. in Silverman's 'Arithmetic of elliptic curves' .
Consider in the field $\mathbb{C}$. We need to verify directly that \begin{equation} \sum_{P\in \phi^{-1}(Q)}e_{\phi}(P)=deg(\phi) \text{ for all }Q\in \mathbb{P}^1 \end{equation}
where $\phi: \mathbb{P}^1\to \mathbb{P}^1$ is a non-constant map, $deg(\phi)=[\mathbb{C}(\mathbb{P}^1):\phi^*(\mathbb{C}(\mathbb{P}^1))]$, $e_\phi(P)$ is the ramification index of $\phi$ at P, i.e. \begin{equation} e_\phi(P)=\text{ord}_P(\phi^*t_{\phi(P)}) \end{equation} and $\pi_{\phi(P)}\in \mathbb{C}(\mathbb{P}^1)$ is a uniformizer at $\phi(P)$.
We have an idea as follows.
Since $\phi$ is a map on $\mathbb{P}^1$, $\phi$ can be written as $f(t)/g(t)$, where $f,g\in \mathbb{C}[\mathbb{P}^1]$ and they have no divisors in common.
Then by the Exercise V.2.6 in Hungerford's Algebra (Page 255), $deg(\phi)=[\mathbb{C}(\mathbb{P}^1):\phi^*(\mathbb{C}(\mathbb{P}^1))]$=max(deg $f$, deg $g$).
Since the field $\mathbb{C}$ is algebraically closed, the uniformizer $\pi_{\phi(P)}$ is a polynomial of degree 1.
Suppose that $Q=\phi(t)=f(t)/g(t)$. Then $f(t)-Qg(t)=0$. Since $f,g$ are polynomials, $f-Qg$ is a polynomial of degree at most max{deg$f$, deg$g$}. Hence it can be written as $f(t)-Qg(t)=(t-P_1)^{n_1}\cdots(t-P_k)^{n_k}$. \begin{equation} \sum n_k\leq max\{\text{deg }f,\text{ deg }g\} \end{equation}
Thus $e_{\phi}(P_i)=\text{ord}_{P_i}(\phi^*\pi_{\phi(P_i)})=\text{ord}_{P_i}(\frac{f(t)-Qg(t)}{g(t)})=n_i$. So \begin{equation} \sum_{P\in \phi^{-1}(Q)}e_{\phi}(P)=\sum n_i\leq max\{\text{deg }f,\text{ deg }g\}=deg(\phi) \end{equation}
But we cannot always attain the '='. For example, if $\text{deg }f<\text{ deg }g$ and $Q=0$; or $\text{deg }f=\text{ deg }g$ and $Q$ is precisely the $l(f)/l(g)$, where $l(f)$ is the leading coefficient of $f$. This contradicts to the conclusion of this exercise.
Are there any errors? Thank you.