Problem

Source: India Postal Set 4 P 5

Tags: set theory, group theory, Binary operation, number theory



Is it possible to define an operation $\star$ on $\mathbb Z$ such that for any $a, b, c$ in $\mathbb Z, (a \star b) \star c = a \star (b \star c)$ holds; for any $x, y$ in $\mathbb Z, x \star x \star y = y \star x \star x=y$?