#include #include using namespace std; class Point { private: double x,y; public: Point(); //default constructor Point( double, double); //parameterized constructor //accessors double getX(); double getY(); //mutators void setX(double xval); void setY(double); //member functions void print(); double distance(Point); double distanceFromOrigin(); }; Point::Point() //default constructor { x=0; y=0; } Point::Point( double xval, double yval) //parameterized constructor { x =xval; y = yval; } //accessors double Point::getX() { return x; } double Point::getY() { return y; } //mutators void Point::setX(double xval) { x = xval; } void Point::setY(double yval) { y = yval; } //member functions void Point::print() { cout<<"The point is ("<name = name; this->color = color; } double area() { // fabs(x1*(y2-y3) + x2*(y3 - y1) + x3(y1-y2))/2 double x1 = vertices[0].getX(); double y1 = vertices[0].getY(); double x2 = vertices[1].getX(); double y2 = vertices[1].getY(); double x3 = vertices[2].getX(); double y3 = vertices[2].getY(); return fabs(x1*(y2-y3) + x2*(y3 - y1) + x3*(y1-y2))/2; } void print() { cout<<"Name: "<