|
CSIS 250 Fall 2000 Project #2
Develop the CPoint class and test functions as discussed during the lectures. Submit the well-documented printed source code and sample output. Provide at least five test cases for each function. Clearly show the operands and the results from each function. Also complete and submit the following self-evaluation table.
Use the following class definition: //class definition //////////////////////////////////////////////////////////// class CPoint { private: int x; int y; public: CPoint (int a=0, int b=0); CPoint (char ch); void display(void) const; void setX (int a); void setY (int b); void setXY (int a, int b); int getX(void) const; int getY(void) const; void getXY (int &a, int &b) const; void copyTo (CPoint &p) const; void copyFrom (const CPoint &p); bool isEqualTo (const CPoint &p) const; };
|