Hint $\rm\,\ f = (x\!-\!a)^m\:\Rightarrow\: f'\,|\:f,\: $ thus we can pull a factor of $\rm\:\color{green}{f'}$ out of the product rule
$\rm\quad \color{#C00}{f'\,|\:f}\:\Rightarrow\:f'\,|\:(fg)' =\, f'g+fg' =\, \color{green}{f'}\,(g+(\color{#C00}{f/f'})g')\ \ $
Analogous remarks hold true for similar product rules, e.g. the difference product rule
$\rm \Delta(fg)\, =\, f\, \Delta g + g\, \Delta f + \Delta f\, \Delta g$
which has a factor of $\rm\:\Delta f\:$ if $\rm\:\Delta f\:|\:f,\:$ and a factor of $\rm\:f\:$ if $\rm\:f\:|\:\Delta f.\:$ This comes in handy when manipulating products, e.g. factorials.
These properties prove fundamental in algorithms for indefinite integration and summation, since they reveal the effect of differentiation and differencing on multiplicity of factors, which allows us to derive simple effective bounds on multiplicity (necessary for effective algorithms).