If $n>3$ prove that $\sum_{k=0}^{n-1} (k-n)\cos\frac{2k\pi}{n}=\frac{n}{2}$. Do you have any ideas on this IIT exercise?

If $n>3$ is an integer, prove that
  $$\sum_{k=0}^{n-1} (k-n)\cos(2kπ /n) = n/2$$ 

In my attempt, I have considered
$$z=cis(2kπ/n), k=[1, 2,..., n-1].$$
Then
$$Re(z)= \cos(2kπ/n).$$
But I've got stuck in the middle of the process, since I got a hard sum to deal with:
$$(z+2z^2+⋯+(n-1) z^{n-1}) - n(z+z^2+⋯+z^{n-1}  ).$$
My problem is in the first factor of the sum above:
$$z+2z^2+⋯+(n-1) z^{n-1}$$
I appreciate your help, fellow mathematicians! 
 A: This is based on your approach.
Let $|z|=1$ and we get all $n$-th unit zeros, so with derivating of
$$1+z+z^2+\cdots+z^{n-1}=\frac{1-z^n}{1-z}$$
we have
$$1+2z+3z^2+\cdots+(n-1)z^{n-2}=\frac{-nz^{n-1}+nz^n+1-z^n}{(1-z)^2}$$
then
$$\Big(z+2z^2+3z^3+\cdots+(n-1)z^{n-1}\Big)-n\Big(z+z^2+\cdots+z^{n-1}\Big)=\frac{z}{(1-z)^2}\Big(1-z^n-n+nz\Big)=\frac{z(1-z^n)}{(1-z)^2}-\frac{nz}{1-z}=-\frac{nz}{1-z}$$
it conclude
$${\bf Re}\sum_{k=0}^{n-1}(k-n)z^k=n-n{\bf Re}\frac{1}{1-z}=\frac{n}{2}$$
A: Let $n-k=r$
$$S=\sum_{k=0}^{n-1} (k-n)\cos\dfrac{2k\pi}n=\sum_{k=0}^n(k-n)\cos\dfrac{2k\pi}n=-\sum_{r=0}^nr\cos\dfrac{2\pi(n-r)}n=-\sum_{r=0}^nr\cos\dfrac{2\pi r}n$$
$$S=-\sum_{k=0}^nk\cos\dfrac{2\pi k}n$$
and we have $$S=-\sum_{k=0}^n(n-k)\cos\dfrac{2\pi k}n$$
$$-2S=n\sum_{k=0}^n\cos\dfrac{2\pi k}n$$
Using $\sum \cos$ when angles are in arithmetic progression, $$\sum_{k=0}^{n-1}\cos\dfrac{2\pi k}n=0$$
$$\implies\sum_{k=0}^n\cos\dfrac{2\pi k}n=0+\cos\dfrac{2\pi n}n=?$$
A: Let $S = z+2z^2+⋯+(n-1) z^{n-1}$. We have $zS = z^2 + 2z^3 + \cdots +(n-1)z^n$ and hence 
\begin{align*}
S - zS &= z + z^2 + \cdots +z^{n-1} - (n-1)z^n \\
&= \frac{1-z^n}{1-z} - 1 - (n-1)z^n
\end{align*}
Hence 
$$S = \frac{1-z^n}{(1-z)^2} - \frac{1+(n-1)z^n}{1-z}$$
