Stretching force, $F=$ $\frac{Y \pi r^{2}\Delta L}{L}$
where the symbols have their usual meanings.
Both the wires are of same material, so $Y$ will be equal,
extension in both the wires is same, so $\Delta L$ will be equal.
$\therefore\quad$ $F$ $\propto$ $\frac{r^{2}}{L}$
$\therefore\quad$ $\frac{F'}{F}$ $=\frac{\left(2r\right)^{2}}{\left(L /2\right)}$ $\times\frac{L}{r^{2}}=8$
or $F'$ $=8 F$ $\quad\ldots\left(i\right)$
Work done in stretching a wire,
$W=\frac{1}{2}\times$ $F\times\Delta L$
For same extension
$W$ $\propto$ $F$
$\therefore\quad$ $\frac{W'}{W}$ $=\frac{F'}{F}=8$ $\quad\left[Using \left(i\right)\right]$
$W'$ $=8W=8\times2 \,J$ $=16 \,J$