Example 15 (Problem from the 45th Moscow Mathematical Olympiad) Find all positive integers $n$ such that $n \cdot 2^{n}+1$ is divisible by 3.
Prove that because $3 \mid n \cdot 2^{n}+1 \Leftrightarrow n \cdot 2^{n} \equiv 2(\bmod 3)$, and when $n=6 k+1(k=0,1,2, \cdots)$,
$$
n \cdot 2^{n}=(6 k+1) \cdot 2^{6 k+1}=(12 k+2) \cdot 4^{3 k} \equiv 2 \cdot(3+1)^{3 k} \equiv 2(\bmod 3) \text {; }
$$
$$
\begin{array}{l}
\text { when } n=6 k+2(k=0,1,2, \cdots) \text {, } \\
n \cdot 2^{n}=(6 k+1) \cdot 2^{6 k+2}=(24 k+8) \cdot 4^{3 k} \equiv 8 \cdot 1^{3 k} \equiv 2(\bmod 3) ;
\end{array}
$$

When $n=6 k+3(k=0,1,2, \cdots)$,
$$
n \cdot 2^{n}=(6 k+3) \cdot 2^{6 k+3}=0(\bmod 3) \text {; }
$$

When $n=6 k+4(k=0,1,2, \cdots)$,
$$
n \cdot 2^{n}=(6 k+4) \cdot 2^{6 k+4} \equiv 1 \cdot 4^{3 k+2} \equiv 1^{3 k+2} \equiv 1(\bmod 3) ;
$$

When $n=6 k+5(k=0,1,2, \cdots)$,
$$
n \cdot 2^{n}=(6 k+5) \cdot 2^{6 k+5} \equiv 2 \cdot(3+1)^{3 k+2} \cdot 2 \equiv 4 \equiv 1(\bmod 3) ;
$$

When $n=6 k(k=0,1,2, \cdots)$,
$$
n \cdot 2^{n}=6 k \cdot 2^{6 k} \equiv 0(\bmod 3) .
$$

Therefore, from the above, it is known that $n \cdot 2^{n}$ is divisible by 3 if and only if $n=6 k+1$ and $6 k+2(k=0,1,2, \cdots)$.