public class RectangleTester {
    public static void main(String[] args) {
        Point p1 = new Point(3, 2);
        Point p2 = new Point(0, 0);
        Rectangle r = new Rectangle(p1, p2);
        System.out.print("Point 1: ");
        System.out.println(p1.toString()); // no hace falta ".toString()"
        System.out.print("Point 2: ");
        System.out.println(p2);
        System.out.print("Rectangle: ");
        System.out.println(r);
        System.out.print("Area: ");
        System.out.println(r.getArea());
        System.out.print("Perimeter: ");
        System.out.println(r.getPerimeter());
    }
}
