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

120% of what number is 102?
What unnatural happenings does Horatio equate with the ghosts appearance?
What was the purpose of mummification? preserving the body for the afterlife preventing decomposition preserving the soul for the afterlife purifying the soul
Which of the following explains how World War I affected Turkish leaders? A. They participated in the League of Nations, but refused to support the idea of self
how did manifest destiny affect Spanish and Mexican rule in California
What is typically placed at the top of a résumé? work background contact information educational experience skills and accomplishments
One is most likely to feel repugnance for that which he or she finds a. puzzling. c. desirable. b. disgusting.
What is an atom that accepts an electron called? a. a cation b. a proion c. an anion d. an isomer
25% of 200 is _________.
What is an object that represents determination