TITLE: Prove: if $n\mid 7^n+6^n$ and $n>1$, then $13\mid n$
QUESTION [8 upvotes]: Prove: if $n\mid 7^n+6^n$ and $n>1$, then $13\mid n$
Let $p$ be the least prime number such that $p\mid n$. 
And I want to show that $p=13$
Let $d$ be the least number such that: $14^d\equiv 0 \pmod {p}$
And by Fermat's little theorem I have: $14^{p-1}\equiv 0 \pmod{p}$
Here I'm stuck

REPLY [6 votes]: $n\mid 7^n\!+6^n\!=:a_n$ odd $\Rightarrow n$ odd, so  $\,a_n = 7^n\!-\!(-6)^n,\,$ so $\,b,c= 7,-6\,$ below $\,\Rightarrow\, p = 13$.
Lemma $ $ If $\,\gcd(b,c)\!=\!1\ $ & $\ 1<n\mid b^n\!-c^n$ then $\,p\mid b\!-\!c\,$ for $\,\color{#c00}{p}=$ least prime factor of $\,n$.
Proof $\,\ \color{#f60}{p\nmid b}\,$ else $\,p\mid n\mid b^n\!-c^n\Rightarrow\,p\mid c,\,$ contra $\,\gcd(b,c)\!=\!1.\,$ $\color{#90f}{p\nmid c}\,$ by symmetry.  If $\ \color{#0a0}{p\nmid b\!-\!c}\ $ $\rm\color{#90f}{then}$ $\!\bmod p\!:\ a:= \frac{b}c\!\not\equiv \color{#0a0}1,\color{#f60}0,$ and $\, a^n\equiv 1,\,$ so $\ {\rm ord}\ a\ge\color{#c00}p,\,$ contra $\ a^{p-1}\equiv 1\,$ by little Fermat, and the Order Theorem $\,(a^n\equiv 1\Rightarrow {\rm ord}(a)\,$ is a factor of $\, n;\,$ but $\,{\rm ord}(a)\neq 1$ by $\,\color{#0a0}{a\neq 1}\,$ so the least value  $\,{\rm ord}(a)\,$ can take is the least factor $> 1\,$ of $\,n,\,$ which is its least prime factor $\,\color{#c00}p).$