1. Modify the Classes project in the Visual C# Step by StepChapter 7Classes folder by adding a new class called Line to the project. A Line class consists of two Point objects. Add a method GetLength to calculate the length of each Line object. Test a Line object by creating a line consisting of origin and bottomRight points in the DoWork method. Call the GetLength method to display the line’s length. Note: The existing Point class must be left intact. Or, if you make any changes to the Point class, private fields must not be changed to public.
Book is Microsoft® Visual C#® Step by Step 9th edition, 2018