public class TestPoint{ public static void main(String[] args){ Point p1 = new Point(); Point p2 = new Point(3.0,4.0); System.out.println(p1.distance()); System.out.println(p2.distance()); } }