Untitled

Anonymous
Plain Text
06/23/2023 9:45 AM
436 B
25
Indexable
Never
Class Point: 
public class Point { 
    private int x, y; 
     public Point() { 
        x = 0; 
        y = 0; 
    } 
     public Point(int x, int y) { 
        this.x = x; 
        this.y = y; 
    } 
     public void setX(int x) { 
        this.x = x; 
    } 
     public void setY(int y) { 
        this.y = y; 
    } 
     public void setXY(int x, int y) { 
        this.x = x; 
        this.y = y; 
    } 
}
Editor is loading...