subject
Engineering, 20.02.2020 20:44 china1283

The volume of a sphere is 4/3πr3, where π has the value of "pi" given in Section 2.1 of your textbook. Write a function called print_volume that takes an argument for r, the radius of the sphere, and prints the volume of the sphere.

Call your print_volume function with three different values for radius.

Write your own function that illustrates a feature that you learned in this unit. The function must take at least one argument. The function should be your own creation, not copied from any other source. Do not copy a function from your textbook or the Internet.

Include all of the following in your Learning Journal:

a. The code for your print_volume function.
b. The inputs and outputs to three calls of your print_volume function.
c. The code for the function that you invented.
d. The inputs and outputs to three calls of your invented function.

ansver
Answers: 2

Another question on Engineering

question
Engineering, 04.07.2019 18:10
Aturning operation is performed with following conditions: rake angle of 12°, a feed of 0.35 mm/rev, and a depth of cut of 1.1 mm. the work piece is aluminum alloy 6061 with t6 heat treatment (a16061-t6). the resultant chip thickness was measured to be 1.0 mm. estimate the cutting force, fc. use shear stress of 207 mpa and coefficient of friction on the tool face of 0.6.
Answers: 1
question
Engineering, 04.07.2019 18:20
An engine runs on the ideal diesel cycle. the cycle has a compression ratio of 20 and a cutoff ratio of 2. the highest temperature in the cycle is 1200 k. if the heat into the system is 300 kj/kg of working fluid and using variable specific heats determine the work produced per mass of working fluid
Answers: 3
question
Engineering, 04.07.2019 19:10
The air in an automobile tire with a volume of 0.015 m3 is at 32°c and 140 kpa gage. determine the amount of air that must be added to raise the pressure to the recommended value of 206 kpa gage. assume the atmospheric pressure to be 128 kpa and the temperature and the volume to remain constant.[r-0.287 kj/kgk]
Answers: 3
question
Engineering, 04.07.2019 19:20
Aseries piping system conveys methyl alcohol. the system consists of 70 m of 1- nominal pipe follow by 50 m of 2-nominal pipe, both schedule 40 commercial steel. the 1-nominal pipe contains 3 90° elbows (regular) anda fully open gate valve, all threaded. the pressure drop through the system is 150 kpa. determine the volume flow rate through the system that is horizontally laid.
Answers: 1
You know the right answer?
The volume of a sphere is 4/3πr3, where π has the value of "pi" given in Section 2.1 of your textboo...
Questions
question
History, 30.04.2021 21:00
question
Mathematics, 30.04.2021 21:00
question
Mathematics, 30.04.2021 21:00
question
Social Studies, 30.04.2021 21:00
Questions on the website: 13722361