write a class encapsulating the concept of a


Write a class encapsulating the concept of a circle? I have been working on this program for awhile and this is all I have so far... What are my flaws in the program besides not having the set and string for my contrsuctor and mutator methodsimport java.util.*;

public class Circle
{

private double centerX;
private double centerY;
private double radius;

public Circle(String X, double Y, double R);
(
centerX = X;
centerY= Y;
radius = R;
)

public Circle(double centerX, double centerY, double radius);
{

Scanner console = new Scanner(System.in);

public double getcenterX(){
return centerX;}

public double getcenterY(){
return centerY;}

public double getradius(){
return radius; }

public double getPerimeter(){
return 2 * Math.PI * radius;}

public double getArea(){
return Math.PI * radius * radius;}


}

System.out.println("TESTING CONSTRUCTORS:");
System.out.println("No-Arguement Circle: Center(" + Centerx + Centery + ") Radius: " + radius );
}

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: write a class encapsulating the concept of a
Reference No:- TGS0416725

Expected delivery within 24 Hours