(N/A) Since the work done depends on the final arrangement of the charges,and not on how they are put together,we calculate the work needed for one way of placing the charges at $A, B, C$ and $D$. Suppose,first the charge $+q$ is brought to $A$,and then the charges $-q, +q,$ and $-q$ are brought to $B, C$ and $D$,respectively. The total work needed can be calculated in steps:
$(i)$ Work needed to bring charge $+q$ to $A$ when no charge is present elsewhere: This is $0$.
$(ii)$ Work needed to bring $-q$ to $B$ when $+q$ is at $A$. This is given by (charge at $B$) $\times$ (electrostatic potential at $B$ due to charge $+q$ at $A$):
$W_2 = -q \times \left(\frac{q}{4 \pi \varepsilon_{0} d}\right) = -\frac{q^{2}}{4 \pi \varepsilon_{0} d}$
$(iii)$ Work needed to bring charge $+q$ to $C$ when $+q$ is at $A$ and $-q$ is at $B$. This is given by (charge at $C$) $\times$ (potential at $C$ due to charges at $A$ and $B$):
$W_3 = +q \left(\frac{+q}{4 \pi \varepsilon_{0} d \sqrt{2}} + \frac{-q}{4 \pi \varepsilon_{0} d}\right) = \frac{q^2}{4 \pi \varepsilon_{0} d} \left(\frac{1}{\sqrt{2}} - 1\right)$
$(iv)$ Work needed to bring $-q$ to $D$ when $+q$ at $A, -q$ at $B,$ and $+q$ at $C$. This is given by (charge at $D$) $\times$ (potential at $D$ due to charges at $A, B$ and $C$):
$W_4 = -q \left(\frac{+q}{4 \pi \varepsilon_{0} d} + \frac{-q}{4 \pi \varepsilon_{0} d \sqrt{2}} + \frac{+q}{4 \pi \varepsilon_{0} d}\right) = -\frac{q^2}{4 \pi \varepsilon_{0} d} \left(2 - \frac{1}{\sqrt{2}}\right)$
Adding the work done in steps $(i), (ii), (iii)$ and $(iv)$,the total work required is:
$W = W_1 + W_2 + W_3 + W_4 = \frac{-q^{2}}{4 \pi \varepsilon_{0} d} \left(0 + 1 + (1 - \frac{1}{\sqrt{2}}) + (2 - \frac{1}{\sqrt{2}})\right) = \frac{-q^{2}}{4 \pi \varepsilon_{0} d} (4 - \sqrt{2})$
$(b)$ The extra work necessary to bring a charge $q_{0}$ to the point $E$ when the four charges are at $A, B, C$ and $D$ is $q_{0} \times$ (electrostatic potential at $E$ due to the charges at $A, B, C$ and $D$). The electrostatic potential at $E$ is zero since the potential due to $A$ and $C$ is cancelled by that due to $B$ and $D$. Hence,no work is required to bring any charge to point $E$.