Write a program in C++ using classes and function overloading, to calculate volume of Cube, Cuboid and a Cylinder, the program

Status
Not open for further replies.
Oct 18, 2018
1
0
10
Write a program in C++ using classes and function overloading, to calculate volume of Cube, Cuboid and a
Cylinder, the program should allow user to enter values. Start by creating a class called Shape with float
member variables l, w and h and integer member variables a and r.
Note:
• Volume of a Cube = a3
• Volume of a Cylinder = πr
2h
• Volume of a Cuboid = l × w × h
• π = 3.14
 
Status
Not open for further replies.