# Calculate Sample standard deviation and MAD

I need to solve this problem for an arbitrary N. I'm not exactly sure how to go about this. I have formulas to calculate both standard deviation and MAD, however I'm not sure what to do with the hint at the bottom. I believe it will help me calculate the sample variance which will give me the standard deviation (the square root of the sample variance), but I'm not sure. Can someone point me in the right direction?

• HINT: Mean of sample = 0. Variance = $2(1+2^2+3^2+...)$ – rightskewed Apr 7 '15 at 23:14
• I understand the mean being 0, however where did the 2 come from for the variance? From the formula I have, with the mean being 0, it seems my variance should be 1/(n-1) * the sum of each value squared (the hint). – C1116 Apr 7 '15 at 23:20
• There are $2n+1$ numbers and not just $n$ – rightskewed Apr 7 '15 at 23:24
• @rightskewed makes sense. so what happened to the 1/(n-1)? – C1116 Apr 8 '15 at 2:59
• I should have written the whole expression. Var=$\frac{1}{2n}*2*\frac{(n)(n+1)(2n+1)}{6}$ – rightskewed Apr 8 '15 at 3:38