"Counting Tricks": using combination to derive a general formula for $1^2 + 2^2 + \cdots + n^2$ I was reading an online article which confused me with the following. To find out $S(n)$, where $S(n) = 1^2 + 2^2 + \cdots + n^2$, one can first write out the first few terms:  

0 1 5 14 30 55 91 140 204 285  

Then, get the differences between adjacent terms until they're all zeroes:  

0 1 5 14 30 55 91 140 204 285
  1 4 9 16 25 36 49 64 81
  3 5 7 9 11 13 15 17
  2 2 2 2 2 2 2
  all zeroes this row

Then it says that therefore we can use the following method to achieve $S(n)$:
$S(n) = 0 {n\choose 0} + 1 {n\choose 1} + 3 {n\choose 2} + 2 {n\choose 3}$.
I don't understand the underlying mechanism. Someone cares to explain?

The key word here is finite differences. See Newton series.
