Okay, that is already not the good way around. You haven't found the derivative yet, hence, it's f(x), not f'(x)

Then, since you already used f(x), you should use something else. Let's take u and v, such that:

,

,

Now, substitute that into f'(x).

Is this a university level answer? Cause I'm only doing high-school calculus, and have no idea on how I would solve by using your method. Is it impossible to do it the method I was doing? Just when I thought I was getting the hang of it, too.

Unfortunately, my calculus teacher is a really stubborn and stern. He prefers us to only use his method despite the fact that other methods are more widespread and easier for students. He'll give us 0 on tests and assignments for using "foreign methods" as he likes to call it.

Now, the 2x is obtained when you differentiate g(x). You first 'lower the power down' next to the bracket, decrease the power by 1 and last but not least, you get the derivative of what is inside the brackets.