Suppose $G$ is a set and $\star$ is an associative binary operation on $G$ such that there is a unique right identity element and every element has a left inverse. Prove that $(G,\star)$ is a group.
Here's my work so far:
We know there is a unique $e \in G$ such that $x \star e = x$ for all $x \in G$. We also know that for each $x \in G$ there exists some $x^{-1} \in G$ such that $x^{-1} \star x = e$. My trouble is with establishing that $e$ is also a left identity element. If I can show that $e \star x = x \star e = x$ for all $x$, then I am able to prove that $x \star x^{-1} = x^{-1} \star x = e$ for all $x \in G$ with the following argument:
\begin{align*} x \star e = x \implies (x \star e) \star x^{-1} &= x \star x^{-1} && \text{Multiplying by } x^{-1} \text{ on the right} \\[3pt] \implies (x \star e) \star x^{-1} &= e && \text{(Defn. of inverse)} \\[3pt] \implies (e \star x) \star x^{-1} &= e && (\text{Assuming } x \star e = e \star x) \\[3pt] \implies e \star ( x \star x^{-1}) &= e && \text{(Associativity)} \\[3pt] \implies x \star x^{-1} &= e && (e \text{ is the unique right identity element}). \end{align*}
My attempts at showing that $e$ is a left identity have been fruitless...I know I somehow must use the fact that $e$ is a unique right identity element because the text explained that without the uniqueness condition, $(G,\star)$ is not a group. Any help would be appreciated!