Question: I understand the program is long and tedius, I need help any way possible. Write in C + + please. Will like the answer if

I understand the program is long and tedius, I need help any way possible. Write in C++ please. Will like the answer if helpful!!
Write a class Point that represents a point on the screen. Hence it has an x and y coordinate (which are integers).
You should write a class definition and the following functions (you must decide if they are members or
friends).
(a) A constructor which is passed two integers, consider whether to use default values.
(b) A copy constructor.
(c) A translate function which is passed a Point and changes the coordinates using the passed in Point. If the
original point is (x,y) and the point (a,b) is passed in then the new coordinates (x',y') are given by the formulas:
x'=x+a,y'=y+b
Note, this function can be implemented using operator overloading.
(d) A move to function. This function is passed a Point and moves the original point to the passed in Point.
(e) A rotate function which is passed an angle and rotates the point by that amount. If the original point is (x,y
and the angle of rotation is , then the new coordinates (x',y') are given by the formulas:
x'=xcos-ysin,y'=xsin+ycos
(f) A distance function that gives the distance between two points. The formula for the distance between (x,y)
and (x',y') is:
(x'-x)2+(y'-y)22
(g) A function that determines if a point is on a given line. The information for the line would be passed in as a
slope and a specific point on the line. Hint: use the point-slope formula for a line.
(h) Functions to access the x and y coordinates. There should be three such functions. One that returns the x-
coordinate, one that returns the y-coordinate and one that returns the Point.
(i) Functions to modify the x and y coordinates.
(j) Overload the assignment operator.
(k) A function called invert that switches the x and y coordinates.
(l) A function that is passed two points and finds the midpoint between them.
(m) A function to convert the point (x,y) into polar coordinates (r,). The conversion equations are:
r=x2+y22,=tan-1(yx)
(n) Overload the input and output operators.
 I understand the program is long and tedius, I need help

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!