G is a group and S is a nonempty finite subset which is closed under multiplication. Show that S is a subgroup of G.
My Attempt
Let S be equal to $\{a_1,a_2.....a_n$} and let it be ordered such that $ a_1a_2.....a_n = a_1$. Multiplying both sides with $a^{-1})$ we get $a_2.....a_n = e$.
Thus e∈S.
$(a_2.....a_n)^{-1}$ = e
$a_n^{-1}.....a_2^{-1}$ = e
We can show that any $a_k^{-1}$ between $a_n^{-1}$ and $a_2^{-1}$ is an element of S by multiplying by $a_n^{}$, $a_{n-1}$.... until we reach $a_{k}$. We can do the same thing from the right starting with $a_2$.
Here's where I'm stuck. I have proved that the inverses for all elements in S exist in S except for $a_1$. Any help on how to prove that would be appreciated.
Also, since I'm new to algebra, I don't know whether the method of multiplying on the left and the right until we reach $a_k$ is formally correct or not. So a more formal way of stating the same would also be really appreciated.
You only need to show that $S$ is closed under inverses (then $1=aa^{-1}$ for any $a\in S$). So let $a\in S$. Consider the elements $a,a^2,a^3,\dots\in S$ since $S$ is finite, this sequence has to repeat at some point, lets say $a^n=a^m$ with $n<m$. But then $1=a^{m-n}$ (by multiplying both sides by $a^{-n}$), hence $a^{m-n-1}$ is the inverse of $a$ and lies in $S$ (note that if $m-n-1=0$ then $1=a^{m-n}=a$).
Regarding your proof: It is not at all obvious that there exists an ordering such that $a_1a_2\dots a_n=a_1$.