An arithmetic progression such that the sum of the first $12$ terms equals the sum of the first $18$ terms:
\begin{multline}
(-29) + (-27) + (-25) + (-23) + (-21) + (-19) +{} \\
(-17) + (-15) + (-13) + (-11) + (-9) + (-7) = -216,\\
\end{multline}
\begin{multline}
(-29) + (-27) + (-25) + (-23) + (-21) + (-19) +{} \\
(-17) + (-15) + (-13) + (-11) + (-9) + (-7) +{} \\
(-5) + (-3) + (-1) + 1 + 3 + 5 = -216. \\
\end{multline}
The sum of the first $21$ terms of the series is
\begin{multline}
(-29) + (-27) + (-25) + (-23) + (-21) + (-19) +{} \\
(-17) + (-15) + (-13) + (-11) + (-9) + (-7) +{} \\
(-5) + (-3) + (-1) + 1 + 3 + 5 +7 + 9 + 11 = -189. \\
\end{multline}
So it is possible to do this with non-zero $a$ and $d,$ namely
$a = -29,$ $d = 2.$
By the distributive law, we have equality of the sum of the first $12$ terms and the sum of the first $18$ terms whenever $a = -29k$ and $d = 2k$
for some constant $k.$
And then the sum of the first $21$ terms is $-189k.$
So the sum of the first $21$ terms could be any real number if $k$ is allowed to be any real number. It can be any multiple of $189$ if the terms must all be integers.
I suspect an error in the transcription of the question, possibly before it was presented to you.
Since the sequence $x_n$ satisfies the necessary properties, we see that the sum of the first 21 terms is $\sum_{i=1}^{21} x_i = \sum_{i=1}^{21} 0 = 0$.
– benguin Aug 13 '16 at 05:43