<s>[INST] How many values does the expression $1 \pm 2 \pm 3 \pm \cdots \pm n$ take? 
How many different values does the expression $1 \pm 2 \pm 3 \pm \cdots \pm n$ take?

I was wondering about this problem and didn't think it was immediately obvious. The answer can't be $2^{n-1}$ since the combinations all might not be unique. I was thinking of looking at partitions of $\{1,2,\ldots,n, k\}$ where $1 \pm 2 \pm 3 \pm \cdots \pm n = k$ and thus the sum must be even. Therefore, $\dfrac{n(n+1)}{2}+k = \dfrac{n(n+1)+2k}{2}$ must be even which means $n(n+1) + 2k$ must be a multiple of $4$ so $n(n+1)+2k = 4m$. Thus if $n \equiv 1,2 \bmod 4$, then $k \equiv 1,3 \bmod 4$ and if $n \equiv 3,0 \bmod 4$ then $k \equiv 0,2 \bmod 4$.
 [/INST] To start with, you can forget about the leading term, $1$.
All that term does is to shift all the values one place to the right
on the number line.
The expression $\pm 2 \pm 3 \pm \cdots \pm n$
has the same number of distinct values as $1 \pm 2 \pm 3 \pm \cdots \pm n$.
From this point until further notice, I'll consider only sums of
the form $\pm 2 \pm 3 \pm \cdots \pm n$.
All possible sums have the same parity.
The minimum sum is $\sum_{i=2}^n(-i) = -\frac{(n+2)(n-1)}{2}$, 
when all the $\pm$ signs
are negative. The sum $-\frac{(n+2)(n-1)}{2} + 2$
is clearly not achievable, but $-\frac{(n+2)(n-1)}{2} + 4$ is,
as long as $n \geq 2$.
Now as long as the sum includes two terms $j - (j+1)$ 
(positive followed by negative), we can change the two terms to
$-j + (j+1)$ and thereby increase the sum by $2$.
If there are no such terms, that is, all the negative terms occur
before any of the positive terms, the sum has the form
$$-2 - 3 - \ldots - (j-1) - j + (j+1) + \ldots + n = k \tag1$$
where $1 \leq j \leq n$. (In the case $j = 1$, all terms are positive.)
We have already considered the case $j = n$.
In the case $j=1$, the sum has the maximum value, 
$\frac{(n+2)(n-1)}{2}$,
and in the case $j=2$, the sum has the second greatest possible value,
$\frac{(n+2)(n-1)}{2} - 4$.
Now suppose instead that $3 \leq j \leq n-1$.
Then we can change the sum on line $(1)$ to
$$2 - 3 - \ldots - (j-1) + j - (j+1) + \ldots + n = k + 2.$$
In other words, if $n > 3$, then except for the values 
$-\frac{(n+2)(n-1)}{2}$,
$\frac{(n+2)(n-1)}{2} - 4$, and $\frac{(n+2)(n-1)}{2}$,
every possible value of the sum 
(including $-\frac{(n+2)(n-1)}{2} + 4$) 
corresponds to another sum that is greater by $2$.
So the possible sums are $-\frac{(n+2)(n-1)}{2}$, $\frac{(n+2)(n-1)}{2}$,
and every integer of the same parity from $-\frac{(n+2)(n-1)}{2} + 4$
to $\frac{(n+2)(n-1)}{2} - 4$, inclusive.
The number of integers in 
$\left[-\frac{(n+2)(n-1)}{2}, \frac{(n+2)(n-1)}{2}\right]$
is $(n+2)(n-1) + 1$, and those of the same parity are 
$\frac{(n+2)(n-1)}{2} + 1$.
So if $n > 3$, the total number of possible sums (excluding the
values $-\frac{(n+2)(n-1)}{2}+2$ and $\frac{(n+2)(n-1)}{2}-2$, 
which are not possible sums) is 
$$\left(\frac{(n+2)(n-1)}{2} + 1\right) - 2 = \frac12(n^2 + n - 4).$$
For example, if $n=4$ then there are $8$ possible sums:
$-9,-5,-3,-1,1,3,5$, and $9$.
By inspection, this formula also gives the number of sums for $n=3$
(the sums are $-5,-1,1,$ and $5$),
but the number of sums for $n=2$ is $2$, which does not agree with
the formula; $n=2$ must be treated as a special case.

If you modify the original expression by making the first term $\pm1$,
that is, if you consider $\pm 1 \pm 2 \pm \cdots \pm n$,
the minimum is $-\frac{n(n+1)}{2}$,
the maximum is $\frac{n(n+1)}{2}$,
and all integers of the same parity between those values are
possible sums.
</s>