// © Copyright 1997, Joseph Bergin. All rights reserved.public class Pair {		public Pair(Object f, Object s)	{	first = f;		second = s;	}		public boolean equals(Object p)	{	if(p instanceof Pair)			return first.equals(((Pair)p).first) && second.equals(((Pair)p).second);		return false;	}		public String toString()	{	String result = first.toString() + " " + second.toString();		return result;	}		public Object first;	public Object second;	}// See also IdentityPair, which compares with == instead of equals.// See also KeyedPair, which compares only the firsts for equality.  