proof that if a repunit number is prime n has to be prime
So a repunit number is a number that it's all digits are 1. For example $R_{2} = 11$ $R_{7} = 1111111$ and so on. Repunit numbers can be represented as $\frac{10^{n} -1}{9}$ in general.
Problem is asking if $\frac{10^{n} -1}{9}$ is prime then $n$ has to be prime. İts easy to see for $n=3k \:\:(k \in \mathbb{Z})$ it is divisible by $3$ and for $n=2m \:\:(m \in \mathbb{Z})$ it is divisible by $11$
But ı stumbled upon how to prove that $n$ is prime