@Override public int hashCode() { int hash = 1; for (Comparable element : elements) hash = 31 * hash + (element != null ? element.hashCode() : 0); return hash; }