6. (1997 China Mathematical Olympiad) Let real numbers $x_{1}, x_{2}, \cdots, x_{1997}$ satisfy the following two conditions:
(1) $-\frac{1}{\sqrt{3}} \leqslant x_{i} \leqslant \sqrt{3}(i=1,2, \cdots, 1997)$;
(2) $x_{1}+x_{2}+\cdots+x_{1997}=-318 \sqrt{3}$.
Find the maximum value of $x_{1}^{12}+x_{2}^{12}+\cdots+x_{197}^{12}$, and explain the reason.
6. For any set of $x_{1}, x_{2}, \cdots, x_{1997}$ that satisfies the given conditions, if there exist $x_{i}$ and $x_{j}$ such that:
$$
\sqrt{3}>x_{i} \geqslant x_{j}>-\frac{1}{\sqrt{3}},
$$

we denote
$$
x_{i}+x_{j}=2 m, x_{i}-x_{j}=2 h .
$$

Then $x_{i}=m+h, x_{j}=m-h$,
$x_{i}^{12}+x_{j}^{12}$ reaches its maximum value.
Therefore, the maximum value of the sum of the 12th powers can only be achieved in the following scenario: at most one variable takes a value in $\left(-\frac{1}{\sqrt{3}}, \sqrt{3}\right)$, and the rest of the variables take values of $\sqrt{3}$ or $-\frac{1}{\sqrt{3}}$.

Suppose $u$ variables take the value $-\frac{1}{\sqrt{3}}, v$ variables take the value $\sqrt{3}, w$ variables take a value in $\left(-\frac{1}{\sqrt{3}}, \sqrt{3}\right)$. Clearly, $w=0$ or 1. When $w=1$, let the value of this variable be $t$. Thus, we have
$$
\left\{\begin{array}{l}
u+v+w=1997, \\
-\frac{1}{\sqrt{3}} \cdot u+\sqrt{3} v+t w=-318 \sqrt{3} .
\end{array}\right.
$$
(2) $\times \sqrt{3}+$ (1) gives $: 4 v+(\sqrt{3} t+1) w=1043$.

Since $(\sqrt{3} t+1) w=1043-4 v$ is an integer, and
$$
0 \leqslant(\sqrt{3} t+1) w<4,
$$

it follows that $(\sqrt{3} t+1) w$ is the remainder when 1043 is divided by 4. This leads to $w=1, t=\frac{2}{\sqrt{3}}$.
Substituting into (1) and (2), we solve to get $u=1736, v=260$.
Therefore, the maximum value of $x_{1}^{12}+x_{2}^{12}+\cdots+x_{1997}^{12}$ is
$$
\left(-\frac{1}{\sqrt{3}}\right)^{12} \cdot u+(\sqrt{3})^{12} \cdot v+t^{12}=\frac{1736+4096}{729}+729 \times 260=189548
$$