Programming Exercise 15, Chapter 11, describes how to design the class pointType to implement a point. Redo this programming exercise so that the class pointType: a. Overloads the stream insertion...


Programming Exercise 15, Chapter 11, describes how to design the class pointType to implement a point. Redo this programming exercise so that the class pointType:


a. Overloads the stream insertion operator, <,>


b. Overloads the stream extraction operator, >>, for easy input. (A point is input as (a, b).)


c. Overloads the assignment operator to copy a point into another point.


d. Overloads the binary operator +, as a member function, so that it returns the distance between two points.


e. Overloads the operator ==, as a member function, so that it returns true if two points are the same; false otherwise.


f. Overloads the operator !=, as a member function, so that it returns true if two points are not the same; false otherwise.


g. Write a program to test your class.





May 18, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here