Add 1 plus 2 plus 3 plus 4. . . all the way to 100.
There is a story behind this problem. It is said that a famous mathematician by the name of Carl Gauss was punished for poor behavior in class, so he was told to stay after school. As punishment, the teacher told Carl to add the numbers from 1 to 100, thinking it was going to take him a long time to do. Gauss completed the problem rather quickly and, thus, got to leave detention early.
The way he did it was he recognized that 1+100 was 101, 2+99 was 101, and 3+98 was 101. This would occur all the way up to 50+51. As a result, there were 50 pairs of numbers that added to 101. Accordingly, Gauss multiplied 50 by 101 in order to get 5050.
We have to find the sum of 1+2+3+. . . +100.
We have a formula to calculate the sum of n numbers as:
So we have:
` Sum=(100(100+1))/2=5050 `
Hence the sum is 5050.