Java OOP GUIDE / WORK POINT CLASS 2 TASK –
PART 1 – CONSIDER THE FOLLOWING POINT CLASS No
work |
||||
TASK – PART 2 – TESTING
THE POINT CLASS Here is my
Tester class:
Note: Both d1
and d2 get the value 4.24. TASK – PART 3 – ADDING A
NEW METHOD Here is my
method:
Note: A
shorter solution would have been to simply call the other distanceFrom
method. TASK – PART 4 – MORE
TESTING Here is the
code I added to the tester class to test the new method:
TASK – PART 5 – PROCESSING
A POINT ARRAY Here is the
code I added to the PointTester class:
Note:
Perimeter is 29.6. |