You will write functions for the volumes of a cone, a hemisphere and an ice cream (a cone with a hemisphere on top). Then you will change a volume from cubic centimetres to litres.
The idea. The volume of a cone is and of a hemisphere . The volumes of joined solids add. One litre is .
Your tasks.
cone_volume, return .hemisphere_volume, return .ice_cream, return the volume of a cone of height h with a hemisphere on top, both with radius r.litres, return the number of litres in a volume given in cubic centimetres.Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…