20
Question Question 20
Find the volume of the cylinder (πr2h) as shown:
Radius = 8 cm
Height = 15 cm
Solution
import math
r = 8
h = 15
v = math.pi * r * r * h
print("Volume of Cylinder =", v)Output
Volume of Cylinder = 3015.928947446201
import
math
r
=
8
h
=
15
v
=
math
.
pi
*
r
*
r
*
h
print
(
"Volume of Cylinder ="
,
v
)
Output
Volume of Cylinder = 3015.928947446201