Proving that if $ab=e$ then $ba=e$ Suppose that instead of the property $ab=ba=e$ a group G has the condition that for every element $a$ there exists an element $b$, such that $ab=e$. Prove that $ba=e$. Is the following a valid proof?

Since $ab=e$ then under the condition of the group there exists an element $k$ such that $bk=e$ for some $k$ in the group.

Now $bk=e$ so $abk=ae$ therefore $(ab)k=a$ and finally $ek=a$ and $k=a$.

Is this a valid proof?
I assume that you mean if for SOME $a,b$ (not every) $ab = e$ then $ba = e$.
Your proof  is valid, but you could write it much easier without playing with $k$. $$ab = e \Rightarrow  bab = b.$$ If you already know the cancellation law, then we are done.  Otherwise you may continue by writing $baba = ba$, so that $(ba)^2 =ba$. Just note that the only idempotent in a group is $e$.
Theorem $(A)$: For every $\{a, b\} \subset \mathbb{R}, \ ab = c \ $ and $\ a \neq 0$
$$\implies b = \frac{c}{a}$$
Proof: $$\begin{align} ab &amp;= c \\ \iff \bigg(\frac{1}{a}\bigg)(ab) &amp;= \bigg(\frac{1}{a}\bigg)c \\ \iff \bigg(\frac{1}{a} \times a\bigg)b &amp;= \bigg(\frac{1}{a}\bigg)c \\ \iff 1\times b &amp;= \bigg(\frac{1}{a}\bigg)c \\ \iff b &amp;= \bigg(\frac{1}{a}\bigg)c \\ \iff b &amp;= \frac{c}{a} \end{align}$$

$(A)$ is derived from the multiplicative cancellation law, which proves that for every $\{a, b, c\} \subset \mathbb{R}, \ ac = bc \ $ and $\ c \neq 0 \Rightarrow a = b$. So now all you have to do is substitute $c = e$ and $b = a$ in the proof of $(A)$ and you can prove that $\ ab = e \Rightarrow ba = e \Rightarrow ab = ba$.