the default behavior, the equals method of object class, equates to true if both references point to the same object.
http://java.sun.com/products/jdk/1.1/docs/api/java.lang.Object.html The equals method for class Object implements the most discriminating possible equivalence relation on objects; that is, for any reference values x and y, this method returns true if and only if x and y refer to the same object (x==y has the value true).
You can override the equals method within your class by using the reference passed to the equals
method
equals(Point p){
if ((this.x == p.x) && (this.y == p.x)){
return true;
}
else {return false;}
}
overriding the toString method
you can return whatever string or string concatenation you beleive to represent the objec