Could some one point out what's wrong with the classes of this program?
#include <iostream>
using namespace std;
class box
{
private:
int height;
int length;
int width;
public:
box();//constructor
int surface_area();
int volume();
void set_dim(int ,int, int);
};
//implementation
box::box(){
int height;
int width;
int length;}
box::int surface_area(){
int sa=2*(length*width+length*height+height*width);
return sa;
}
box::int volume(){
return length*width*height;
}
box::void set_dim(int l,int w,int h){
int height=h;
int length=l;
int width = w;
}
int main(){
box a;
a.set_dim(2,3,4);
cout<<"The volume is: "<<a.volume()<<endl;
cout<<"The surface area is: "<<a.surface_area()<<endl;
return 0;
}