主题:[讨论]请提供各类成员函数的实现代码
class Rectangle
{
double * width;
double * height;
public:
Rectangle(double x,double y);
~ Rectangle();
Rectangle(Rectangle & obj);
Rectangle & operator=( Rectangle & obj);
double GetWidth() const;
double GetHeight() const;
void SetWidth(double wid);
void SetHeight(double hei);
};
{
double * width;
double * height;
public:
Rectangle(double x,double y);
~ Rectangle();
Rectangle(Rectangle & obj);
Rectangle & operator=( Rectangle & obj);
double GetWidth() const;
double GetHeight() const;
void SetWidth(double wid);
void SetHeight(double hei);
};