Isoelectronic species refers to two atoms, ions or molecules that have the same electronic structure and the same number of valence electrons term means "equal electric" or "equal charge". Isoelectronic chemical species typically display similar chemical properties.
\begin{matrix}{\mathrm{Sm}}^{2+}\rightarrow \mathrm{electron}=60 \\ {\mathrm{Er}}^{3+}\rightarrow \mathrm{electron}=65 \\ {\mathrm{Tb}}^{2+}\rightarrow \mathrm{electron}=63 \\ {\mathrm{Tm}}^{4+}\rightarrow \mathrm{electron}=65\end{matrix}} (not isoelectronic)
While Yb2+ and Lu3+ both will have 68 electrons. and Eu2+ and Tb4+ both will have 61 electrons.so, they are isoelectronic with each other.
Note: According to NTA only option D is given as answer but option A and D both will be the correct answer.