(AIME 1987) Find the number of ordered triples $(a,b,c)$ of positive integers satisfying the following condtions. Problem: [AIME 1987] Find the number of ordered triples $(a,b,c)$ of positive integers for which $[a,b]=1000$, $[b,c]=2000$ and $[c,a]=2000$, where $[x,y]$ denotes the $\text{lcm}$ of $x$ and $y$.
My Attempt: Clearly $$a=2^{m_1}5^{n_1},b=2^{m_2}5^{n_2}\text{ and }c=2^{m_3}5^{n_3}.$$
Then we need to find solutions to the following set of equations:
$$\max\{m_1,m_2\}=3$$
$$\max\{m_2,m_3\}=4$$
$$\max\{m_3,m_1\}=4$$
$$\max\{n_1,n_2\}=3$$
$$\max\{n_2,n_3\}=3$$
$$\max\{n_3,n_1\}=3$$
Frankly I have never seen a system like this before and I would like to know a methodical way of solving such equations. 

From $$\max\{n_1,n_2\}=3$$ we gather that either $n_1$ or $n_2$ must be 3, while the other must only be one of $0, 1, 2, $ or $3$. From $$\max\{n_2,n_3\}=3$$ $$\max\{n_3,n_1\}=3$$ we find the same result must hold for the pairs $n_2,n_3$ and $n_3, n_1$. But how can this result hold for all 3 pairs? Clearly at least two of $n_1, n_2, n_3$ must be $3$ else the result would fail for one pair. The third $n_i$ in the trio may be any of $0,1,2,3$. Now we must count how many ways there are to choose $n_1, n_2, n_3$. There are $\binom 32$ ways to choose two to be $3$, and for the last we have $4$ options. This gives $4 \binom 32 = 12$ options for $n_1,n_2,n_3$. Can you use similar logic to find $m_1, m_2, m_3$?
