Answer
2850 turns.
Work Step by Step
$U=\frac{1}{2}LI^2$. Find the inductance.
$$L=\frac{2U}{I^2}=\frac{2(0.390J)}{(12.0A)^2}=5.417\times10^{-3}H$$
Example 30.3 gives the inductance of a toroidal solenoid as $L=\frac{\mu_0 N^2 A}{2 \pi r}$. Solve for N and evaluate, using the numbers given.
$$N=\sqrt{\frac{2\pi r L}{\mu_0 A}}$$
$$N=\sqrt{\frac{2\pi (0.150m)( 5.417\times10^{-3}H)}{(4\pi \times10^{-7}Wb/m \cdot A) (5.00\times10^{-4}m^2)}}=2850$$