JavaScript:实现计算各种形状的体积算法
/*
Calculate the volume of the shapes
Volume for Cuboid
Volume for Cube
Volume for Cone
Volume for Pyramid
Volume for Cylinder
Volume for Triangular Prism
Volume for Pentagonal Prism
Volume for Sphere
Volume for Hemisphere
*/
/*
Calculate the volume for a Cuboid
return width * length * height
*/
const volCuboid = (width, length, height)