/* * Copyright ©2020 Hal Perkins. All rights reserved. Permission is * hereby granted to students registered for University of Washington * CSE 333 for use solely during Spring Quarter 2020 for purposes of * the course. No other use, copying, distribution, or modification * is permitted without prior written consent. Copyrights for * third-party components of this work must be honored. Instructors * interested in reusing these course materials should contact the * author. */ #ifndef RECTANGLE_H_ #define RECTANGLE_H_ #include "./Point.h" class Rectangle { public: Rectangle(const Point &ul, const Point &lr); Point getul() const; Point getlr() const; int area() const; bool contains(const Point &p) const; private: Point ul_, lr_; }; #endif // RECTANGLE_H_