# Missing step while (classically) deriving Friedmann equation

I'm trying to understand the classical derivation of Friedmann equation but I'm missing one step.

So, I start with accelerations, where $a$ is a scale factor

$\ddot{a}=-\frac{GM}{a^{2}}$

$\ddot{a}=-\frac{4\pi G}{3}\rho a$

Now multiply both sides by $\dot{a}$, and here is the question: Why LHS is

$\dot{a}\ddot{a}=\frac{1}{2}\frac{d}{dt}\left(\dot{a}^{2}\right)$

$\frac{1}{2}\frac{{\rm d}}{{\rm d}t}\big((\dot{a})^{2}\big) = \frac{1}{2}*2*\dot{a}*\frac{{\rm d}}{{\rm d}t}\big(\dot{a}\big) = \dot{a}\ddot{a}$. Maybe you don't recognize the notation - a dot is often used to denote a time derivative. Thus two dots indicates a double time derivative.