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

Find an equation of the tangent to the curve at the given point by both eliminating the parameter and without eliminating the parameter. x = 6 + ln(t), y = t2 +
the first clause states that the election of members of Parliament should be
The American colonies decided to make their new states republics because they
A TV had height:width in ratio 3:4.in a scale drawing the width is 10cm,what would the height be
Salim is writing a paragraph comparing and contrasting the Maori and Haida cultures. Which sentence best illustrates his point about how each group views human
What is the area of the sector bound by the center of the circle and arc CD in the circle below? radius equals 10 feet central angel is 40 degrees
What number must you add to complete the square? x2 + 4x = 15 A. 16 B. 4 C. 2 D. 8
True of false once an action plan is in place it should not be changed
The estimated total cost, y, of a child’s toy is partially based on the number of batteries used, x. The cost of one battery is $0.75. The toy itself costs $12.
What makes michelangelo a renaissance man?