I'm working through a practice problem and have the solution but don't understand how the rearranging happens:
I have: \begin{align*} \ldots &= \big(n(n+1)\big) + 2(n+1) \\ &= (n + 2)(n + 1)\end{align*}
What is actually happening to get from the first line to the next one?
Hint: $$a\cdot b + c \cdot a = a\cdot (b+c)$$ for every $a,b,c \in \Bbb R$.