【问题描述】编写一个基于对象数组的程序,用成员函数实现多个功能,求3个长方柱的体积。要求用成员函数实现以下功能:
1、由键盘分别输入3个长方柱的长、宽、高;
2、计算长方柱的体积;
3、输出3个长方柱的体积。
【输入形式】用户由键盘分别输入3个长方柱的长、宽、高。
【输出形式】输出3个长方柱的体积。
【样例输入】
10 10 10
12 13 14
15 2 34
【样例输出】
Please input length,width and height:
The volume is:1000
Please input length,width and height:
The volume is:2184
Please input length,width and height:
The volume is:1020
【样例说明】用户根据提示由键盘分别输入3个长方柱的长、宽、高。依次输出3个长方柱的体积。
【评分标准】 结果完全正确得10分,每个测试点5分。提交程序名为:hanxin.c或hanxin.cpp
#include<iostream>
using namespace std;
class cuboid
{
public:
int chang;
in