Hack Forums
[Java] I don't understand this question, and how to go about it. - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [Java] I don't understand this question, and how to go about it. (/showthread.php?tid=4778010)



I don't understand this question, and how to go about it. - Just Ice - Apr 14, 2015

Hi :)
I know there are many knowledgeable people out there, I have an assessment question I do not understand very well, I was wondering if someone could please take a look and help me out by pointing me in the right direction or even just giving a brief layout/overview that is easier to understand.

Task
For this task you have to define a class Circle2D to represent a circle with a point in two dimensions labeled x and y and a radius. To test Circle2D class you also need to define a test class. The Circle2D class has the following state and functionality:
• Two double data fields named x and y that specify the centre of the circle with getter methods.
• A data field radius with a getter method
• A no-arg constructor that creates a default circle with (0, 0) for (x, y) and 3 for radius.
• A constructor that constructs a circle with the specified x, y, and radius.
• A method getArea() that returns the area of the circle
• A method getPerimeter() that returns the perimeter of the circle
• A method contains(double x, double y) that returns true if the specified point (x, y) is inside this circle
• A method overlaps(Circle2D circle) that returns true if the specified circle overlaps with this circle.
Draw the UML diagram for the class and then implement the class. Write a test class program that creates a Circle2D object c1(new Circle2D(2, 2, 2.5)), display its areas and perimeter, and display the result of c1.contain(3,3), c1.containes(new Circle2D(4, 5, 8.5)), and c1.overlaps(new Circle2D(3, 5, 0.3)).


* - M0dy - Apr 14, 2015

I honestly don't know how to break this down, it's kinda self explanatory, but I can help you figure it out if you like.
PM me your Skype.


* - Just Ice - Apr 14, 2015

(Apr 14, 2015 12:19 AM)M0dy Wrote:  I honestly don't know how to break this down, it's kinda self explanatory, but I can help you figure it out if you like.
PM me your Skype.

Yeah I was hoping that wasn't the case, pming you now :) thankyou!


* - Maxiim - Apr 14, 2015

Are there any particular steps you don't understand? Or all of them?
Or do you just not understand the words?


* - Aman.96 - Apr 17, 2016

I also don't understand that question(lol yeah same assignment!), just ice if u get the idea can u post in simple language? OR maxiim as u asked I just did not understand words..Thanks.