package shapes;

public class Circle extends Shape {
  private double r;
  
  public Circle(double _x, double _y, double _r) {
    // every child class has to call a constructor of their parent in some way or another
    // unless there is a no-argument constructor in the parent
    super(_x,_y);
    r = _r;
  }
  public double area() { return Math.PI * r * r; }
  public double perimeter() { return 2 * Math.PI * r; }
}