How many solutions are there for $x^{2}\equiv49\:\left(10^{6}\right)$ ?
I can see that $x=\pm7$ are two solutions, and I guess that $x$ is a solution to the given congruence iff $\left(\frac{x}{7}\right)^{2}\equiv1\:\left(10^{6}\right)$. So as $\frac{x}{7}$ has to be an integer, we can write $x=7y$ and then look for number of solutions to $y^{2}\equiv1\:\left(10^{6}\right)$ (right?). How can we continue from here?
EDIT:
The answer is 8.
I think it is somehow related to the fact that $$\left(\mathbb{Z}/_{10^{6}}\mathbb{Z}\right)^{\times}\cong\left(\mathbb{Z}/_{2^{6}}\mathbb{Z}\right)^{\times}\times\left(\mathbb{Z}/_{5^{6}}\mathbb{Z}\right)^{\times} $$ and that
- $y^{2}\equiv1\:\left(2^{6}\right)$ has 4 solutions
- $y^{2}\equiv1\:\left(5^{6}\right)$ has 2 solutions
But I don't see exactly why. Is that right?
Your edit contains two essential observations; making explicit the isomorphism $$\left(\mathbb{Z}/{10^{6}}\mathbb{Z}\right)^{\times}\ \longrightarrow\ \left(\mathbb{Z}/{2^{6}}\mathbb{Z}\right)^{\times}\times\left(\mathbb{Z}/{5^{6}}\mathbb{Z}\right)^{\times}: x+10^6\Bbb{Z}\ \longmapsto\ (x+2^6\Bbb{Z},x+5^6\Bbb{Z}) ,\tag{1}$$ tells you that $x^2\equiv49\pmod{10^6}$ if and only if $$x^2\equiv49\pmod{2^6}\qquad\text{ and }\qquad x^2\equiv49\pmod{5^6}.$$ You already note that these congruences have $4$ and $2$ solutions, respectively. This gives you $4\times2=8$ pairs $(x_1,x_2)\in\left(\mathbb{Z}/{2^{6}}\mathbb{Z}\right)^{\times}\times\left(\mathbb{Z}/{5^{6}}\mathbb{Z}\right)^{\times}$ such that $$x_1^2\equiv49\pmod{2^6}\qquad\text{ and }\qquad x_2^2\equiv49\pmod{5^6}.$$ Because ($1$) is an isomorphism, every such pair corresponds to a unique $x\in\left(\mathbb{Z}/_{10^{6}}\mathbb{Z}\right)^{\times}$ satisfying $x^2\equiv49\pmod{10^6}$. Hence there are precisely $8$ solutions to the original congruence.