A question asked me to calculate the integral of (x+1)/(x^2)

So I split the integration into (x/x^2) + (1/x^2)

and for an answer I got (x)ln(x-1)/(x) + C

Is it okay to split an integration into two parts like I did?

Sorry, im not sure how to use math symbols on forums so my equation is all messy