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

Farmer brown had ducks and cows. one day she noticed that the animals had a total of 1414 heads and 4444 feet. how many of the animals were ducks and how many w
Yo (tener) __________ 15 años.
which of the following events occurred in Los Angeles between 1970 and 2000? I. The white population increased. II. The Hispanic and black populations increased
You should wash your hands _______. After cutting carrots, before cutting tomatoes After putting clean dishes away Before putting on disposable gloves Before go
The line "'Bad time for planting a seed,'" is a metaphor for what?
There is no solution for the absolute value inequality in the picture below, True or False?
URGENT PLEASE HELP! Formal, Functional perceptual regions of Maryland!!!
The first step in the industrial recovery of zinc from the zinc sulfide ore is roasting, that is, conversion of ZnS to ZnO by heating: 2ZnS(s)+302(g)- 2ZnO (s)+
When taking a standardized test, make sure you: A. Skip to the hardest questions in each section. B. Carefully read passages and instructions. C. Read
A triangle has an area of 288.6 square kilometers and a height of 26 kilometers. What is the length of the base?