Gauss Trick (Summing up a series of number )

1 - Problem

Summing up a series of number $$1 + 2 + \dots + 50 + 51 + \dots + 99 + 100$$

2 - Solution

There is a pattern, there is 50 pairs of value 101:

• $1 + 100$
• $2 + 99$
• $50 + 51$

The total is then $$50 * 101 = 5050$$