brandonrhodes8637 brandonrhodes8637
  • 03-03-2020
  • Engineering
contestada

What does the following program segment do? Declare Count As Integer Declare Sum As Integer Set Sum = 0 For (Count = 1; Count < 50; Count++) Set Sum = Sum + Count End For

Respuesta :

thamimspartan thamimspartan
  • 10-03-2020

1225

Explanation:

This segment helps initialize sum as 0. The for loop is used to increment with every execution and it is added to the sum. The loop runs 49 times and every time the count is added to the sum. In short it is the sum of first 49 natural numbers i.e 1+2+3+......+49.

Answer Link

Otras preguntas

How do enhancers accelerate the transcription of a gene?
Sixty-three is 70% of what number?
Why do basketball players need balance?
describe a model that represents 3/3 x 4/4?
4 friends share 3 oranges equally. How much does each friend get?
What was the United States'' principal use of Guam in the late 19th century and early 20th century?
The exam had 60 questions. Phelix got 85 •/• (percent) correct. How many questions did he answer correctly?
What useful product did Benjamin Franklin invent from his lightning experiment?
divide 8/12 to find equivalent fraction?
At a restaurant after every 12th visit you receive a free drink. After every 15th visit you receive a free dessert. At which visit will you first receive a free