hey i need help with understanding how to do this

Given the functions
[tex]\begin{gathered} g(n)\text{ = 2n-4} \\ \text{and} \\ h(n)=n^2\text{ +1-n} \end{gathered}[/tex]Required: (g ° h)(n)
solution:
[tex]\begin{gathered} (g\text{ }\circ\text{ h)(n) is expressed as }g(h(n)). \\ thus, \\ (g\text{ }\circ\text{ h)(n) = }g(h(n))\text{ } \end{gathered}[/tex]g(h(n)) is evaluated by substituting the h(n) function into the g(n) function.
Thus,
[tex]\begin{gathered} g(h(n))\text{ = g(}n^2\text{ +1-n)} \\ \Rightarrow2(n^2\text{ +1-n})-4 \\ \text{open brackets} \\ 2n^2+2-2n-4 \\ \text{collect like terms} \\ 2n^2-2n+2-4 \\ \Rightarrow g(h(n))=2n^2-2n-2 \\ \end{gathered}[/tex]Hence, the function (g ° h)(n) is evaluated to be
[tex]2n^2-2n-2[/tex]