各位好友,谭浩强书上的题,帮忙看下哪不对啊
#include <iostream>using namespace std;
class chang
{
public:
chang(int h ,int w,int l)
{
height=h;
wide=w;
lon=l;
}
int volume();
private:
int height;
int wide;
int lon;
};
int chang::volume(4,4,5)
{
return (height*wide*lon);
}
int main()
{
chang v1;
vi.volume;
cout <<"the volume is :"<<v1.volume<<endle
return 0;
}