Basically, this is asking you to subtract g(x) from f(x).
(f - g)(x) = (x^2 + x - 5) - (4x^2 - 2x + 1)
Distribute the negative sign into the second trinomial:
(f - g)(x) = x^2 + x - 5 - 4x^2 + 2x - 1
Combine like terms:
(f - g)(x) = -3x^2 + 3x - 6
There are no domain restrictions for this function. In other words, x can be any number without making the function undefined.