Testing General Cases

This may be obvious, but you should always test your program with several general cases. These should be very similar to what your program will encounter when actually running. If you don't know what those will look like, try generating a few test cases using the other parts of your code. If that's not possible, start by using an easy test case and then try and make them as difficult or as complicated as possible.

public static void main(String[] args) {
	Point pt1 = new Point(-300000,400000);
	Point pt2 = new Point(0,0);
	System.out.println("The distance between " + pt1
		+ " and " + pt2 + " is " +  Point.distance(pt1,pt2));
}
  1. Test each of your classes with two general cases - one simple and one hard.