public class FigureTester {
    public static void main(String[] args) {
        Point p1 = new Point(3, 2);
        Point p2 = new Point(-1, -1);
        Point p3 = new Point(0, 0);
        int radius = 4;
        Rectangle r = new Rectangle(p1, p2);
        Circle c = new Circle(p1, radius);
        Triangle t = new Triangle(p1, p2, p3);
        System.out.print("Point 1: ");
        System.out.println(p1);
        System.out.print("Point 2: ");
        System.out.println(p2);
        System.out.print("Point 3: ");
        System.out.println(p3);
        System.out.print("Radius: ");
        System.out.println(radius);
        System.out.print("Rectangle (p1,p2): ");
        System.out.println(r);
        System.out.print("Area: ");
        System.out.println(r.calculateArea());
        System.out.print("Perimeter: ");
        System.out.println(r.calculatePerimeter());
        System.out.print("Circle (p1, radius): ");
        System.out.println(c.toString());
        System.out.print("Area: ");
        System.out.println(c.calculateArea());
        System.out.print("Perimeter: ");
        System.out.println(c.calculatePerimeter());
        System.out.print("Triangle (p1, p2, p3): ");
        System.out.println(t.toString());
        System.out.print("Area: ");
        System.out.println(t.calculateArea());
        System.out.print("Perimeter: ");
        System.out.println(t.calculatePerimeter());
    }
}
