A question when solving $\displaystyle \lim_{h\to 0}\dfrac{g(a+h)-2g(a)+g(a-h)}{h^2}=g''(a)$ $g$ is $C^2$ and I want to show
$$\displaystyle \lim_{h\to 0}\dfrac{g(a+h)-2g(a)+g(a-h)}{h^2}=g''(a)$$
I'm confused in one step when trying to solve this by the mean value theorem
Since $$\displaystyle \lim_{h\to 0}\dfrac{g(a+h)-2g(a)+g(a-h)}{h^2}=\lim_{h\to 0} \displaystyle \dfrac{g(a+h)-g(a)-(g(a)-g(a-h))}{h^2}$$
Also, since $g\in C^2$ I can say $g$ is once differentiable everywhere, by mean value theorem, we have $$g(a+h)-g(a)=g'(t)h, \text{ for some } t \in (a,a+h)$$ and $$g(a)-g(a-h)=g'(s)h, \text{ for some } s\in (a-h,a)$$
Thus:
$$ \displaystyle \lim_{h\to 0}\dfrac{g(a+h)-2g(a)+g(a-h)}{h^2}=\lim_{h\to 0} \dfrac{g'(t)-g'(s)}{h}$$
Since the $g\in C^2$, the derivative of $g$ should be differentiable everywhere, so $${g'(t)-g'(s)}=g''(\xi)(t-s), \text{ for some } \xi\in (s,t)$$
Thus$$\lim_{h\to 0} \dfrac{g'(t)-g'(s)}{h}=\lim_{h\to 0}\dfrac{g''(\xi)(t-s)}{h}$$
By the continuity of $g''$, I know that $\lim_{h\to 0} g''(\xi)=g''(\lim_{h\to 0} \xi)=g''(a)$
Then I'm wondering how should I deal with $\dfrac{t-s}{h}$?
I let $t=a+\theta_1h$ and $s=a-\theta_2h$ where $\theta_1, \theta_2\in (0,1)$
Thus $$\dfrac{t-s}{h}=\dfrac{(\theta_1+\theta_2)h}{h}=\theta_1+\theta_2$$
Then result becomes $g''(a)(\theta_1+\theta_2)$
I know probably somewhere I get wrong. Any help? Thanks!

We can apply  l'Hospital's rule. Let $u(h) = g(a+h)-2g(a)+g(a-h)$ and $v(h) = h^2$. Then
$$\frac{u(h)}{v(h)} = \dfrac{g(a+h)-2g(a)+g(a-h)}{h^2} \tag{1} .$$
Both numerator and denominator go to $0$ as $h \to 0$. Thus, to check whether $\lim_{h\to 0} \frac{u(h)}{v(h)}$ exists, we can consider
$$\frac{u'(h)}{v'(h)} = \dfrac{g'(a+h)-g'(a-h)}{2h} \tag{2} .$$
Again both numerator and denominator go to $0$ as $h \to 0$. Now we consider
$$\frac{u''(h)}{v''(h)} = \dfrac{g''(a+h)+g''(a-h)}{2} \tag{3} .$$
But obviously
$$\lim_{h\to 0} \dfrac{g''(a+h)+g''(a-h)}{2} = g''(a)$$
and the desired result follows.
