Correct answer: 1 kJ
The energy stored in a capacitor is $U=\frac12 CV^2$. Substituting $C=5\times10^{-6}\,\text{F}$ and $V=2\times10^4\,\text{V}$ gives $U=\frac12\times5\times10^{-6}\times(2\times10^4)^2=1000\,\text{J}$. Hence the required energy is $1\,\text{kJ}$.