zsdrfhn zsdrfhn
  • 03-01-2021
  • Computers and Technology
contestada

write a program to print the sum of series
1/2+3/4+5/6+/8+.......19/20

Respuesta :

Cytokine
Cytokine Cytokine
  • 03-01-2021

numerator = 1

denominator = 2

total = 0

while denominator != 20:

   total += (numerator/denominator)

   numerator+=2

   denominator+=2

print(total)

I wrote my code in python 3.8. Best of luck.

Answer Link

Otras preguntas

Who was Júlio Mazzei
Some historians have claimed that by allowing Anglo immigration into Texas, the Mexican government ultimately lost the territory. Support or refute this claim w
Explain Dr. King's "legitimate and unavoidable impatience.
Talk about ida mae life in the south
What idea, achievement, or life event is associated with Plato? A. tutored Alexander the Great B. condemned to death by poison C. thought philosopher-kings s
can somebody tell me how to solve this i'm begging.
When a computer generates random digits, the probability that any particular digit in the set {0, 1, 2, ..., 9} is generated on any individual trial is 1/10 = 0
What factors made the United States a superpower after World War II?
In 2022 the chiefs regular season was 14-3 .What was their winning percentage? You may use your ipad calculator.Round your answer to the nearest thousands
Eric has 240 coins in his collection 11/20 of the coins are pennies 4/20of the coins are nickels the rest of the coins are quarters How many quarters are there