The commutator subgroup $G'$ of $G$, is the set of all "long commutators"

This is a question in Rotman's Group Theory:

(P.Yff). For any group $G$, show that $G'$ is the subset of all “long commutators”: $$ G' = \{ a_1 a_2 \dotsm a_n a_1^{-1} a_2^{-1} \dotsm a_n^{-1} : \text{$a_i \in G$ and $n \geq 2$} \}. $$ (Hint (P.M. Weichsel). $$ (a b a^{-1} b^{-1}) (c d c^{-1} d^{-1}) = a (b a^{-1}) b^{-1} c (d c^{-1}) d^{-1} a^{-1} (a b^{-1}) b c^{-1} (c d^{-1}) d. ) $$

(Original image here.)


Here is an elementary proof by induction. $$a_1\cdots a_{n-1} a_n a_1^{-1}\cdots a_{n-1}^{-1}a_n^{-1}=(a_1\cdots a_{n-1})a_n (a_{n-1}\cdots a_1)^{-1} a_n^{-1}.$$ We insert the term $(a_{n-1}\cdots a_1)^{-1}(a_{n-1}\cdots a_1)$ before $a_n$ in the RHS of above the equation, and get that the RHS is equal to $$(a_1\cdots a_{n-1})(a_{n-1}\cdots a_1)^{-1}(a_{n-1}\cdots a_1)a_n (a_{n-1}\cdots a_1)^{-1} a_n^{-1}.$$ We are almost done: the last four terms form a commutator, whereas the first two terms form a long commutator with $n-1$ symbols, which by induction, should be in $G'$. Thus, $X\subseteq G'$ (Derek Holt concludes this by a simpler argument in comment after question). Obviously $X$ contains $G'$.


Based on the suggestion by Derek Holt, here´s my answer.

Let be $x \in X$, then $x = a_1\cdots a_na_1^{-1}\cdots a_n^{-1}$. Lets consider the rigth coset of $G'$ in $G$ with respect to $x$, $G'x \in G/G'$. We know that $G/G'$ is abelian, Thus

$$G'x = G'a_1\cdots a_na_1^{-1}\cdots a_n^{-1} = G'a_1a_1^{-1}\cdots a_na_n^{-1} = G'e = G'$$

Then we conclude

$$G'x = G' \Longleftrightarrow x \in G'$$

Then $X \subseteq G'$, which completes the proof.