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

why is an objects density expressed as a combination of two units
36.8% of what number is 28.52
What is 5/8 equal to
what is the net force if you push a cart to the right with 5N of force and a friend pushes the cart to the left with 5N of force
6. Which choice shows the proper way to use a colon? Warnings are written: on the following labels medicines, cleaning products, and some foods. Warning: If tak
What is 3.2 x 10^-4 m/h in centimeters per second? a) 8.889 × 10^−6 cm/s b) 8.889 × 10^−5 cm/s c) 1.152 × 10^−5 cm/s d) 1.152 × 10^−7 cm/s
According to Gibbon, in what ways has "primitive man progressed over time? what assures the author that this progress will continue?
When is the product of two integers less than or equal to both of the two factors?
find the slope of the line that goes through the points (-15,70) and (5,10) and (2,7) and (6,3).
what is 8/32 is simplest form