@pagan Hi pagan, thank you for your answer and patience. I tried your code and it worked for the specific case. By the way, when I changed the code to "assuming y(0)::finite", Maple aslo worked out the result. However, I have a follow-up question on the same subject. Please refer to the following lines of code.
Maple returned "y(x)=x^n*C1+x^(-n)(-C1-4)+4". My intention was to ask Maple to solve the ODE assuming that n was a positive integer so that C1=-4 and the coefficient in front of x^(-n) would disappear. I tried to juxtapose another condition "n::posint" along with y(0)::finite in my assumption argument, but Maple complained that no assumption can be made about n as it is a constant.
Have you any suggestions? Thank you again for your help.