4. Given that $[x]$ represents the greatest integer not exceeding $x$, the number of integer solutions to the equation $3^{2 x}-\left[10 \cdot 3^{x+1}\right]+ \sqrt{3^{2 x}-\left[10 \cdot 3^{x+1}\right]+82}=-80$ is $\qquad$
4. 2 .
$$
3^{2 x}-\left[10 \cdot 3^{x+1}\right]+82+\sqrt{3^{2 x}-\left[10 \cdot 3^{x+1}\right]+82}-2=0 \text {, i.e., }\left(\sqrt{3^{2 x}-\left[10 \cdot 3^{x+1}\right]+82}+\right.
$$
2) $\cdot\left(\sqrt{3^{2 x}-\left[10 \cdot 3^{x+1}\right]+82}-1\right)=0$, so $3^{2 x}-\left[10 \cdot 3^{x+1}\right]+81=0$, then $3^{2 x}-10 \cdot 3^{x+1}+$ $81 \leqslant 0$, which gives $3 \leqslant 3^{x} \leqslant 27$, hence $1 \leqslant x \leqslant 3$. Upon verification: when $x=1,3$, the original equation holds, and when $x=2$, the original equation has no solution.