answersLogoWhite

0

int sum = 0;

int i;

for(i = 0; i < n; ++i) {

sum += i;

}

User Avatar

Wiki User

16y ago

Still curious? Ask our experts.

Chat with our AI personalities

ProfessorProfessor
I will give you the most educated answer.
Chat with Professor
LaoLao
The path is yours to walk; I am only here to hold up a mirror.
Chat with Lao
ReneRene
Change my mind. I dare you.
Chat with Rene
More answers

n+(n-1)+(n-2)...

* * * * *

=n*(n + 1)/2

User Avatar

Wiki User

14y ago
User Avatar

The first prime numbers are 2 and 3. Their sum is 5.

User Avatar

Wiki User

15y ago
User Avatar

The sum of the first prime numbers is 5

Because the first prime numbers are 2 & 3.

Thus , 2 + 3 =5

The sum is 5

I hope you understand my reason for my answer.

By grade 4 th student

byeee

User Avatar

MARYAM MULLA

Lvl 2
3y ago
User Avatar

it is n(n+1)/2

User Avatar

Wiki User

14y ago
User Avatar

Add your answer:

Earn +20 pts
Q: What is the Sum of first n natural numbers?
Write your answer...
Submit
Still have questions?
magnify glass
imp