Programming Java assignment help

Define a class Point with a constructor public Point(double x, double y) and accessor methods getX,getY. Design and implement a toString method for this class. Define an abstract class shape with an instance variable of class Point, a constructor, a concrete method public void moeveBy(double dx, double dy) that moves the point by the given amount, and an abstract method public Point getCenter().Provide concrete subclasses Circle,Rectangle.Line,Square with constructors public Circle(Point center, double radius),public Rectangle(Point topLeft,double width, double height), public square(point topLeft, double side) and public Line(Point from, Point to). For each subclass, implement getCenter and toString(), which will print all details fo the shape plus  the coordinates of its center point.Supply a tester class called TestShapes that implements aPoint, and an array of Shape and insert into the array, one of each kind of shape subclass. Use a loop to call the toString method of each shape in the array. Now use a llop to ask the user for the coordinates fo a point and move each shape in the array by a different amount, next use a loop to print out the polymorphic array.

Save Time On Research and Writing
Hire a Pro to Write You a 100% Plagiarism-Free Paper.
Get My Paper
Calculate your order
Pages (275 words)
Standard price: $0.00
Client Reviews
4.9
Sitejabber
4.6
Trustpilot
4.8
Our Guarantees
100% Confidentiality
Information about customers is confidential and never disclosed to third parties.
Original Writing
We complete all papers from scratch. You can get a plagiarism report.
Timely Delivery
No missed deadlines – 97% of assignments are completed in time.
Money Back
If you're confident that a writer didn't follow your order details, ask for a refund.

Calculate the price of your order

You will get a personal manager and a discount.
We'll send you the first draft for approval by at
Total price:
$0.00
Power up Your Academic Success with the
Team of Professionals. We’ve Got Your Back.
Power up Your Study Success with Experts We’ve Got Your Back.
Live Chat+1 763 309 4299EmailWhatsApp