devadharsansajeev514
devadharsansajeev514 devadharsansajeev514
  • 25-09-2021
  • Computers and Technology
contestada

Define a class Sphere to input radius of a sphere and compute the volume of it. Volume = πr3 (where π=3.14)​

Respuesta :

Аноним Аноним
  • 25-09-2021

Lets use Python

Program:-

[tex]\tt r=(float(input("Enter\:the\:radius\:of\:Sphere=")))[/tex]

[tex]\tt V=4/3*3.14*r**3[/tex]

[tex]\tt print("Volume\:of\:the\:sphere=",V)[/tex]

Output:-

[tex]\tt Enter\:the\:radius\:of\:the\:sphere=3[/tex]

[tex]\t Volume\:of\:the\:Sphere=103.4[/tex]

Answer Link

Otras preguntas

How many grams of Cu2S could be produced from 9.90 g of CuCl with an excess of H2S gas?
Please help me! 1. The honest man stays home to _____. A. Eat and sleep B. Smoke and read C. Sing and dance D. Cry and scream (I think the answer is A? The othe
What is republican institution and how did the Northwest Ordinance extend republican institution into new territories?
How did Louis XVI’s weak leadership contribute to the growing crisis in France?
A number x divided by 7 is less than -3(inequality and solution of inequality)
which of the following describes a similarity between the Iran-Contra scandal and the Bay of Pigs invasion
What is the explanation for feather beds being warm
Henry Picked 20 oranges and 6 apples from an orchard. What is the ratio of the number of apples to oranges?
What important events led to the spread of communism and the creation of the US Policy?
Which statement is true about carbon? A) It shares its valence electrons. B) It has two valence electrons. C) It is non-reactive. D) It is a metal.