NOTE: y' means the derivative of y, that is dy/dx.

math expression

So

math expression

This question requires us to integrate, and in the process, to find the constant of integration.

Put u = 2x + 1.

Now du = 2dx

So

math expression

So

math expression

Now if x = 0 then y = 2 (from the question).

math expression

and this gives K = 5/3.

So

math expression

is the required function.