Question: In [this](https://en.wikipedia.org/wiki/Taylor%27s_theorem#Proof_for_Taylor.27s_theorem_in_one_real_variable) link I don't understand two last lines in that segment. 

> 
> \begin{align}
> \lim\_{x\to a} \frac{f(x) - P(x)}{(x-a)^k} &= \lim\_{x\to a} \frac{\frac{d}{dx}(f(x) - P(x))}{\frac{d}{dx}(x-a)^k} = \cdots = \lim\_{x\to a} \frac{\frac{d^{k-1}}{dx^{k-1}}(f(x) - P(x))}{\frac{d^{k-1}}{dx^{k-1}}(x-a)^k}\\
> &=\frac{1}{k!}\lim\_{x\to a} \frac{f^{(k-1)}(x) - P^{(k-1)}(x)}{x-a}\\
> &=\frac{1}{k!}(f^{(k)}(a) - f^{(k)}(a)) = 0
> \end{align}
> 
> 
> 

I know it says that it follows from the definition of the derivative at $x=a$ but can someone explain this to me more thoroughly ?

Answer: 
$P(x) = \sum\_\limits{n=0}^k \frac {f^{(n)}(a)(x-a)^n}{n!}\\
P^{(k-1)}(x) = f^{(k-1)}(a) + f^{(k)}(a)(x-a)$

Plug that into to:

$\frac{1}{k!}\lim\_\limits{x\to a} \frac{f^{(k-1)}(x) - P^{(k-1)}(x)}{x-a}\\
\frac{1}{k!}\lim\_\limits{x\to a} \frac{f^{(k-1)}(x) - f^{(k-1)}(a) - f^{(k)}(a)(x-a)}{x-a}\\
\lim\_\limits\limits{x\to a} \frac{f^{(k-1)}(x) - f^{(k-1)}(a)}{x-a} - \frac{f^{(k)}(a)(x-a)}{x-a}$

And the equation on the left equals $f^{(k)}(a)$ by the definition of the derivative.

What does it mean?
$P(x)$ is the best $k$ degree polynomial in a neighborhood of $a.$
This follows from L'Hopital Rule applied $k$ times: [see here](https://en.m.wikipedia.org/wiki/L%27H%C3%B4pital%27s_rule). 
This isn't just an immediate consequence of the definition of derivative.