Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iomanip>
- using std::setw;
- #include "Point.h"
- ostream &operator<<( ostream &output, const Point &number )
- {
- output << "(" << number.xCoordinate << "," << number.yCoordinate << ")";
- return output;
- }
- istream &operator>>( istream &input, Point &number )
- {
- input.ignore();
- input >> setw( 1 ) >> number.xCoordinate;
- input.ignore();
- input >> setw( 1 ) >> number.yCoordinate;
- input.ignore();
- return input;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement