Answer
It should be shortened by 0.5 mm.
Work Step by Step
In a day, the clock should count off 86400 seconds. Instead, it counts off only 86400-21 = 86379 seconds. Therefore, the current period is too long by a factor of 86400/86379, and the pendulum should be shortened to make it swing more quickly.
$$T_{new}=\frac{86379}{86400}T_{old}$$
The period of a pendulum is given by $T=2 \pi \sqrt{\frac{\mathcal{l}}{g}}$.
$$2 \pi \sqrt{\frac{\mathcal{l}_{new}}{g}}=\frac{86379}{86400}2 \pi \sqrt{\frac{\mathcal{l}_{old}}{g}}$$
$$\mathcal{l}_{new}=(\frac{86379}{86400})^2\mathcal{l}_{old}$$
$$\mathcal{l}_{new}=(\frac{86379}{86400})^2(0.9930m)=0.9925m$$
The pendulum should be shortened by 0.0005m = 0.5 mm.