Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ifndef H_CLASSRECT3
- #define H_CLASSRECT3
- #include <iostream>
- using namespace std;
- class rectangleType
- {
- friend ostream& operator<<(ostream&, const rectangleType&);
- friend istream& operator>>(istream&, rectangleType&);
- public:
- void setDimension(double l, double w);
- double getLength() const;
- double getWidth() const;
- double area() const;
- double perimeter() const;
- void print() const;
- rectangleType operator+(const rectangleType&) const;
- rectangleType operator*(const rectangleType&) const;
- bool operator==(const rectangleType&) const;
- bool operator!=(const rectangleType&) const;
- rectangleType();
- rectangleType(double l, double w);
- private:
- double length;
- double width;
- };
- #endif
Advertisement
Add Comment
Please, Sign In to add comment