If G is a finite set closed under an associative operation such that ax=ay forces x=y and ua=wa forces u=w, for every a,x,y,u,w in G, prove that G is a group.
this is a good question! let $\displaystyle G=\{x_1, \cdots , x_n \}.$ then $\displaystyle G=\{x_1x_i: \ 1 \leq i \leq n \}$ by the left cancellation property and so $\displaystyle x_1x_{i_0}=x_1,$ for some $\displaystyle 1 \leq i_0 \leq n.$ let $\displaystyle x_{i_0}x_1=x_j.$ then by associativity we
have: $\displaystyle x_1^2=x_1x_{i_0}x_1=x_1x_j,$ and thus by the left cancellation property $\displaystyle x_1=x_j$ and hence $\displaystyle x_{i_0}x_1=x_1.$ the claim is that $\displaystyle x_{i_0}=1_G.$ by the right cancellation property: $\displaystyle G=\{x_ix_1: \ 1 \leq i \leq n \}.$
thus for any $\displaystyle x_j$ there exists $\displaystyle x_k$ such that $\displaystyle x_j=x_kx_1.$ thus: $\displaystyle x_jx_{i_0}=x_k(x_1x_{i_0})=x_kx_1=x_j.$ now let $\displaystyle x_{i_0}x_j=x_r.$ then $\displaystyle x_j^2=x_jx_{i_0}x_j=x_jx_r,$ and so by the left cancellation property: $\displaystyle x_r=x_j.$
thus $\displaystyle x_{i_0}x_j=x_j.$ this proves that $\displaystyle x_{i_0}=1_G.$ so the only thing left is to show that every element of G has an inverse. let $\displaystyle x_s \in G.$ then $\displaystyle G=\{x_sx_i: \ 1 \leq i \leq n \}.$ thus there exists $\displaystyle x_t \in G$ such
that $\displaystyle x_sx_t=1.$ so every element of G has a right inverse. particularly $\displaystyle x_tx_u = 1,$ for some $\displaystyle x_u \in G.$ but then $\displaystyle x_u=x_sx_tx_u=x_s.$ hence $\displaystyle x_tx_s=1$ and the proof is complete.