Problem: The sets $ A =\{z : z^{18}= 1\} $ and $ B =\{w : w^{48}= 1\} $ are both sets of complex roots of unity. The set $ C =\{zw : z\in A\ \text{and}\ w\in B\} $ is also a set of complex roots of unity. What is the number of distinct elements in $C$?
My work: $A$ is the 18th roots of unity, and $B$ is the 48th roots of unity. I found that there are $6$ roots shared between both $A$ and $B$, and $C$ is not just the intersection of $A$ and $B$.
There are $18$ numbers in $A$, and $48$ numbers in $B$. $C$ is a subset of the $144$th roots of unity (144 is LCM of $18$ and $48$).
From here I am not sure how to solve the problem. Hints would be great but a full solution would be fine too (I have spent more than enough time on this and I'm not sure not much motivation I have to continue.)
We can write $$A=\{e^{2k\pi i/18}\mid k=0,1,\ldots,17\}\quad\hbox{and}\quad B=\{e^{2l\pi i/48}\mid l=0,1,\ldots,47\}\ ,$$ and so $$\eqalign{C &=\{e^{(2k\pi i/18)+(2l\pi i/48)}\mid k=0,1,\ldots,17,\,l=0,1,\ldots,47\}\cr &=\{e^{2\pi i(8k+3l)/144}\mid k=0,1,\ldots,17,\,l=0,1,\ldots,47\}\ .\cr}$$ So, the question is, how many different values modulo $144$ are taken by the expression $8k+3l$, with $k,l$ satisfying the conditions in $C$. The answer is: all of them, and moreover, we need only take $k=0,1,2$. For then we get $$\eqalign{ k=0,\quad 8k+3l&=0,3,6,9,\ldots,141\cr k=1,\quad 8k+3l&=8,11,\ldots,143,146,149\cr &\equiv2,5,8,11,\ldots,143\cr k=2,\quad 8k+3l&=16,\ldots,145,148,151,154,157\cr &\equiv1,4,7,10,\ldots,142\ .\cr}$$ All other $k$ will merely give duplicates of the same $144$th roots of unity.