I am taking macro course this Fall and my calculus is quite rusty. So in the lecture notes they derive the following: $$ \begin{split} MPL&=\frac{dY}{dL}\\&=\frac{d(ALf(k))}{dL}\\&=Af(k)+ALf′(k)(−K)/(L^2A)\\&=A(f(k)−kf′(k))\\&=w \end{split} $$ Specifically, I don't quite understand how they got $Af(k) + ALf'(k) (-K)/(L^2A)$ from $d(ALf(k))/dL?$
Let me also clarify that k = K/AL
Honestly, I am stuck at this point and guess will be doing a lot of differentiation like this during the entire course. Would really appreciate if someone could clarify the differentiation part.