5 Let real numbers $a_{1}, a_{2}, \cdots, a_{100}$ satisfy:
(1) $a_{1} \geqslant a_{2} \geqslant \cdots \geqslant a_{100} \geqslant 0$;
(2) $a_{1}+a_{2} \leqslant 100$;
(3) $a_{3}+a_{4}+\cdots+a_{100} \leqslant 100$.

Find the maximum value of $a_{1}^{2}+a_{2}^{2}+\cdots+a_{100}^{2}$.
5. $a_{1}^{2}+a_{2}^{2}+\cdots+a_{100}^{2} \leqslant\left(100-a_{2}\right)^{2}+a_{2}^{2}+a_{3}^{2}+\cdots+a_{100}^{2}$
$$\begin{array}{l}
\leqslant 100^{2}-\left(a_{1}+a_{2}+\cdots+a_{100}\right) a_{2}+2 a_{2}^{2}+a_{3}^{2}+\cdots+a_{100}^{2} \\
=100^{2}-a_{2}\left(a_{1}-a_{2}\right)-a_{3}\left(a_{2}-a_{3}\right)-\cdots-a_{100}\left(a_{2}-a_{100}\right) \\
\leqslant 100^{2}
\end{array}$$

Equality holds when $a_{1}=100, a_{i}=0(i>1)$ or $a_{1}=a_{2}=a_{3}=a_{4}=50, a_{j}=$ $0(j>4)$.