Evaluate the sum. Evalute the following sum: $ 1 + 2 + 2 + 3 + 4 + 4 + 5 + 6 + 6 + . . . .+ (n-1) + n + n$. 
I tried doing it but I keep getting the wrong answer. I've used known sums to solve it.

Assuming $n$ is even
$$S=1 + 2 + 2 + 3 + 4 + 4 + 5 + 6 + 6 + . . . .+ (n-1) + n + n$$
$$S=(1+2+3+\cdots+(n-1)+n)+(2+4+6+\cdots+n)$$
$$S=\sum_{k=1}^{n} k +\sum_{k=1}^{n/2} 2k$$
$$S=\frac{n(n+1)}{2}+\frac{n}{2}\left(\frac{n}{2}+1\right)=
\frac{2n(n+1)}{4}+\frac{n(n+2)}{4}
=\frac{3n^2+4n}{4}$$
