Point p1 = new Point(1, 2); Point p2 = new Point(1, 2); bool arePointsEqual = p1.Equals(p2);
Point p1 = new Point(1, 2); Point p2 = new Point(3, 4); bool arePointsEqual = p1.Equals(p2);In this example, we create two Point objects with different x and y coordinates. Then, we use the Equals method to compare them and store the boolean result in the arePointsEqual variable. Since both points have different coordinates, the result will be false. These examples utilize the System.Drawing package library.