A university student completed courses worth 3 credits and some courses worth 4 credits. The student earned a total of 52 credits after completing 15 courses. How courses worth 4 credits did the student complete?

Let x be the number of courses worth 4 credits that the student completed.

The student completed 15 - x courses worth 3 credits.
The student earned 3(15 - x) + 4x = 52 credits.
Multiplying through the parentheses, we get 45 - 3x + 4x = 52.
Combining like terms, we get x = 52 - 45 = 7.
The student completed 7 courses worth 4 credits. Answer: \boxed{7}.

are you sure

Apologies for the mistake in the initial response.

Let x be the number of courses worth 3 credits that the student completed.
Then, 15 - x is the number of courses worth 4 credits that the student completed.

The total credits earned by completing courses worth 3 credits is 3x.
The total credits earned by completing courses worth 4 credits is 4(15 - x).

So, 3x + 4(15 - x) = 52.
Expanding the expression gives 3x + 60 - 4x = 52.
Combining like terms gives -x + 60 = 52.
Subtracting 60 from both sides gives -x = -8.

Multiplying by -1 gives x = 8.
So, the student completed 8 courses worth 3 credits and 15 - 8 = 7 courses worth 4 credits.

Therefore, the student completed 7 courses worth 4 credits.