It's about correct implementations of equals and hashCode.
equals only looks at x and not at y, so hashCode should not look at y. Options 4 and 5 only look at x so these match. Option 1 however does not return just y - it sets y to 0 and only then returns y (or 0).
Remember, returning a constant is always a correct (yet inefficient) implementation for hashCode.