rhayrhay78
rhayrhay78 rhayrhay78
  • 04-06-2021
  • Computers and Technology
contestada

write an algorithm to calculate the sum of integer ​

Respuesta :

ANP01
ANP01 ANP01
  • 12-06-2021

Answer:

Step 1:Start

Step 2: declare a variable and initialize with ‘0’ to store the sum of the number.

Step 3: take input for the number of numbers to be calculated sum of.

Step 4: Loop through the given range and accept inputs or generate numbers.

Step 5: add the current number according to the loop with the present value of the variable declared in (step 3) and store in the same variable

Step 6: print the value of the variable declared in (step 3) with relevant message.

Step 7: Stop

Explanation:

Answer Link

Otras preguntas

How did Niccolo Machiavelli’s book The Prince set him apart from other writers of the Renaissance?
If 2/5 of a number is added to 1/3 of the same number ,the sum is 22. What is the number?
what is 12minus 2 multiply 6 plus 2 divide by 2
If 2/5 of a number is added to 1/3 of the same number ,the sum is 22. What is the number?
What would cause a decrease in the quality of circulating red blood cells
what do I do to figure out this problem:3x+8=26+x
what is 12minus 2 multiply 6 plus 2 divide by 2
Amy raised £n for charity. Chris raised £18 more then any. The mean amount raised by the two of them is £45. Work out how much money each one of them raised
Jim has gotten scores of 99 and 93 on his first two tests. what score must he get on his third test to keep an average of 90 or greater
How do we use the Pythagoras theorem in "everyday life".