<s>[INST] Find all n such that : $3 \mid (n2^{n}+1)$ Question : 
Determine all natural numbers n such that 3 
divides $n\cdot2^{n}+1$
Actually I don't have any ideas to approach but
my efforts : 
I see $n=1,2,7,8,13,14$ so I think : 
$n=6k+1$ and $n=6k+2$ $k\in \Bbb{N} $
If I'm not wrong but I don't know how ? I prove it ?
 [/INST] $2^n \equiv (-1)^n \pmod 3$.
So if $n$ is even then $n2^n + 1\equiv n+1 \equiv 0 \pmod 3$ and $n\equiv -1\pmod 3$.
And so $n\equiv 0 \pmod 2$ and $n\equiv 2\pmod 3$ so $n\equiv 2\pmod 6$.
And indeed $(6k+2)2^{6k+2}+1=(6k+2)4^{3k+1}+1\equiv (6k+2)*1^{3k+1} +1\equiv 6k + 2+ 1\equiv 0 \pmod 3$.
If $n$ is odd then $n2^n+1  \equiv -n+1\equiv 0 \pmod 3$ so $n\equiv 1\pmod 3$.
And so $n\equiv 1 \pmod 2$ and $n\equiv 1 \pmod 3$ so $n\equiv 1 \pmod 6$.
And indeed $(6k+1)2^{6k+1}+1\equiv 2^{6k+1}+1\equiv 4^{3k}*2 + 1\equiv 1^{3k}*2 + 1 \equiv 2+ 1\equiv 0\pmod 3$.
... 
To check that $n\equiv 0,3,4,5\pmod 6$ can not be solutions, clearly $n\equiv 0,3\pmod 6$ imply $3|n$ so $3\not \mid n2^{n} + 1$.
And $(6k + 3 + i)2^{6k+3 + i}+1\equiv i2^{6k+ 3+i}+1\equiv i4^k*2^{3+i}+1\equiv i2^32^i\equiv i8*2^i +1\equiv -i2^i+1\pmod 3$ and $-2^1+1 \equiv -1\pmod 3$ and $-2*2^2+1\equiv -7\equiv -1\pmod 3$.
</s>