(c) Here, $\mathrm{\Delta}l = x;Y = \ \frac{F/A}{\mathrm{\Delta}l/L}\ \ or\ F = \frac{YA\mathrm{\Delta}l}{L}\ $
The work is done from 0 to x (change in length),
So the average distance = $\frac{0 + \mathrm{\Delta}l}{2} = \frac{\mathrm{\Delta}l}{2}\ $
Work done = Force $\times$ distance
= $\frac{YA\mathrm{\Delta}l}{L} \times \frac{\mathrm{\Delta}l}{2} = \ \frac{YA(\mathrm{\Delta}l)^{2}}{2L} = \frac{YAx^{2}}{2L}$