finite abelian groups and exp(G)

exercise: Let $G$ be an abelian finite group and suppose $n$ is the smallest integer such that $g^n =e$ for all $g\in G$.

Given a decomposition of G as a product of cyclic groups from prime power orders, find $n$. 

I used these two lemmas:

$\square$ definition: $exp(G)$ is the smallest integer $n$ such that $g^n=e$ for all $g \in G$.

$\square$ $exp(G_1 \times G_2 \times ... \times G_n)=lcm (G_1,G_2,...,G_n)$

$\square$ If G is cyclic, $exp(G)=|G|$  So in our case $n=exp(G)=exp(G_{p_1}^{k_1} \times G_{p_2}^{k_2} \times ... \times G_{p_n}^{k_n})=lcm(p_1^{k_1},...,p_n^{k_n})$

What's wrong here?

Nothing is wrong. What you wrote is correct. However, the answer could arguably be put into a slightly nicer form if we separate out the distinct primes in the decomposition of $G$ and use the fact that the lcm of powers with the same base is simply their maximum.
More precisely, if $q_1,\dots,q_n$ are the distinct primes dividing $|G|$, then we can write $G$ as $$G = H_1 \times H_2 \times \cdots \times H_n$$ where each $H_i$ has order a power of $q_i$; in other words, this is the decomposition of $G$ as the direct product of its Sylow subgroups. The original decomposition $G = G_{p_1}^{k_1} \times G_{p_2}^{k_2} \times \cdots \times G_{p_m}^{k_m}$ can be put into this form simply by grouping together all the factors according to the value of $p_i$; for instance, $H_1$ can be written as the product of all the factors $G_{p_i}^{k_i}$ such that $p_i=q_1$.
Next we may write $H_i$ as a product of cyclic groups, each of order a power of $q_i$: $$H_i = Z_{q_i}^{m_{i,1}} \times Z_{q_i^2}^{m_{i,2}} \times \cdots \times Z_{q_i^{\alpha_i}}^{m_{i,\alpha_i}}$$ with $m_{i,\alpha_i}>0$. In this case, we have $\exp(H_i)=q_i^{\alpha_i}$ and hence $\exp(G)=\prod_{i=1}^n q_i^{\alpha_i}$.
• First of all, thank you for your response. "if we separate out the distinct primes in the decomposition of G" you mean that $G=G_{p_1}^{k_1} \times G_{p_2}^{k_2} \times ... \times G_{p_n}^{k_n}$ while $p_1,p_2,...,p_n$ are all distinct? so I don't understand why "with the same base". – letisya Oct 1 '15 at 19:28