Sum of all absolute values of difference of the numbers 1,2,.....n taken two at a time 
The sum of all absolute values of the differences of the numbers $1,2,3,\ldots, n$, taken two at a time, i.e. $$\sum_{j\le i\le n}\left|i-j\right|$$ equals:
(A) $\binom{n-1}3$  (B) $\binom n 3$  (C) $\binom{n+1}3$  (D)$\binom{n+2}3$

Please give me hints on starting off with this problem. Kindly don't put the whole answer.
(Original scan of problem)
 A: The sum of all absolute values of the differences of the numbers 1,2,3,…,n, taken two at a time is
$\begin{align}
S(n)
&=\sum_{i=1}^n\sum_{j=1}^{n}|i-j|\\
&=\sum_{i=1}^n\sum_{j=1}^{i-1}|i-j|
+\sum_{i=1}^n\sum_{j=i+1}^{n}|i-j|\\
&=\sum_{i=1}^n\sum_{j=1}^{i-1}(i-j)
+\sum_{i=1}^n\sum_{j=i+1}^{n}(j-i)\\
&=\sum_{i=1}^n\sum_{j=1}^{i-1}j
+\sum_{i=1}^n\sum_{j=1}^{n-i}j\\
&=\sum_{i=1}^n\frac{i(i-1)}{2}
+\sum_{i=1}^n\frac{(n-i)(n-i+1)}{2}\\
&=\sum_{i=1}^n\left(\frac{i(i-1)}{2}
+\frac{(n-i)(n-i+1)}{2}\right)\\
&=\sum_{i=1}^n\left(\frac{i(i-1)+(n-i)(n-i+1)}{2}\right)\\
&=\sum_{i=1}^n\left(\frac{i^2-i+(n-i)^2+(n-i)}{2}\right)\\
&=\frac12\sum_{i=1}^n\left(i^2-i+n^2-2ni+i^2+n-i\right)\\
&=\frac{n(n^2+n)}{2}+\sum_{i=1}^n\left(i^2-i-2ni\right)\\
&=\frac{n(n^2+n)}{2}+\frac{n(n+1)(2n+1)}{6}-(2n+1)\frac{n(n+1)}{2}\\
&=\frac{n(n+1)}{2}\left(n+\frac{(2n+1)}{3}-(2n+1)\right)\\
&=\frac{n(n+1)}{6}\left(3n+(2n+1)-3(2n+1)\right)\\
&=\frac{n(n+1)}{6}\left(3n-(2n+1)\right)\\
&=\frac{n(n+1)}{6}\left(n-1\right)\\
&=\frac{(n-1)n(n+1)}{6}\\
&=\binom{n+1}{3}\\
\end{align}
$
(Whew!)
There are probably simpler ways,
but this is my way.
A: Let $f(n)=\sum_{1\le j\le i\le n}|i-j|$. Then $f(n+1)=f(n)+\sum_{1\le j\le n}|n-j|=f(n)+\sum_{0\le j\le n-1}j$.
You may know a formula for the latter sum and then make a suitable ansatz that can be shown by induction.
A: First af all, the modulus is unnecessary as $i \ge j.$ Next, the sum $$ \sum_{j\le i\le n}(i-j)= \sum_{j=1}^{j=n}\sum_{i=j }^{i=n} (i-j).$$ The inner sum $$\sum_{i=j }^{i=n} (i-j)=\frac 1 2 (n+1)^2-\frac 1 2 n-\frac 1 2-j(n+1)+\frac 1 2 j^2+\frac 1 2 j .$$  Therefore, the sum under consideration equals $$\sum_{j=1}^{j=n}\left(\frac 1 2 (n+1)^2-\frac 1 2 n-\frac 1 2-j(n+1)+\frac 1 2 j^2+\frac 1 2 j \right)= \frac 1 6 (n^3-n) =C_{n+1}^{3}. $$ 
A: After having seen @marty cohen 's answer I'd argue as follows:
The sum $S$ in question is equal to the number of unit intervals of the form
$$[l,l+1]\qquad (0\leq i-1<l<j\leq n)\ ,$$
counted with multiplicity. Each such interval determines a three-element subset of $\{0,1,2,\ldots,n\}$ of the form $\{i-1,l,j\}$ with $i-1<l<j\ $, and conversely: For any three-element subset $\{i-1,l,j\}$ of $\{0,1,2,\ldots,n\}$ we obtain an interval $[l,l+1]\subset[i,j]$ that is counted in the sum $S$ as one of the $j-i$ unit segments between $i$ and $j$. 
It follows that
$$S={n+1\choose 3}\ .$$
A: If you fix $j=1$, then let $i$ range you get: $1+2+..+(n-1)$. 
If you fix $j=2$, then let $i$ range you get: $1+2+..+(n-2)$. 
...
If you fix $j=n-1$, then let $i$ range you get: $1$. 
If you put them all together you get a total of $(n-1)$ number of $1$'s, $(n-2)$ number of $2$'s,..., $1$ number of $(n-1)$'s. Thus your sum equals: 
$$\sum_{k=1}^{n-1}k\cdot (n-k)$$Which equals: $n\sum_{k=1}^{n-1} k-\sum_{k=1}^{n-1}k^2$, and using the well know formulas (and some algebra) you get $n^3/6-n/6$, which is equal to $\binom{n+1}{3}$
