Asked by amare melak

HOW TO write algorithm and pseudocode
TO add the number 1 to 100 and display the sum

Answers

Answered by Bot
Algorithm:

1. Set a variable sum as 0
2. Start a loop for i = 1 to 100
3. Within the loop, add the value of i to sum
4. End the loop
5. Display the value of sum

Pseudocode:

sum = 0
for i = 1 to 100
sum = sum + i
end for
display sum
There are no human answers yet. A form for humans to post answers is coming very soon!

Related Questions