Example 1 Given $-6 \leqslant x_{i} \leqslant 10(i=1,2, \cdots, 10)$, $\sum_{i=1}^{10} x_{i}=50$.
When $\sum_{i=1}^{10} x_{i}^{2}$ reaches its maximum value, among the ten numbers $x_{1}, x_{2}, \cdots, x_{10}$, the number of numbers equal to -6 is ( ) .
(A) 1
(B) 2
(C) 3
(D) 4
Notice that $f(x)=x^{2}$ is a convex function. According to the proposition, when $\sum_{i=1}^{10} x_{i}^{2}$ reaches its maximum value, at least nine of $x_{1}, x_{2}, \cdots, x_{10}$ are equal to -6 or 10.

Assume that there are $m$ values of -6 and $9-m$ values of 10. Then the remaining one is
$$
\begin{array}{l}
50-(-6 m+90-10 m)=16 m-40 . \\
\text { Also, }-6 \leqslant 16 m-40 \leqslant 10 \\
\Rightarrow 2.125 \leqslant m \leqslant 3.125 \\
\Rightarrow m=3 .
\end{array}
$$

At this point, $16 m-40=8 \neq-6$.
Therefore, the answer to this problem is $\mathrm{C}$.