Prove that 17 divides 1111111111111111 (16 1's) and doesn't divide 11111111 I need to prove that $17$ divides $\underbrace{1111111111111111}_{\text{16 1's}}$ and doesn't divide $\underbrace{11111111}_{\text{8 1's}}$ by using congruence.

I know that $\underbrace{1111111111111111}_{\text{16 1's}}= \frac{10^{16}-1}{9}$ and that $10^{15}\equiv{1}\pmod {17}$. But how do I use these two facts to figure out if $17$ divides $1111111111111111$?
$1111111111111111=10^{15} + ... + 1 = \large{(10^{16} -1)\over9}$

$10^2 \equiv -2\pmod {17}$

$10^{16} - 1 = (-2)^8 - 1 = 256 -1 \equiv 1 -1 = 0\pmod {17}$

$11111111= \large{(10^8 -1 )\over9} $

$10^2 \equiv -2\pmod {17}$

$10^8 - 1 \equiv (-2)^4 - 1 = 15 \pmod {17}$
$$
1111111111111111 = \sum_0^{15} 10^ i
$$

Since 17 is prime, the 16 values $10^0$, $10^1$, ..., $10^{15}$ are distinct and non-zero mod 17. (Otherwise we have $10^m = 17k$ for some integers $k$, $0\leq m &lt; 17$ in which 17 is a factor of the RHS but not of the LHS.)

Thus 

$$
1111111111111111 = \sum_0^{15} 10^i
$$

$$
= 1 + 2 + 3 + ... + 16 \mod 17
$$

$$
= (1 + 16) + (2 + 15) + ... + (8 + 9) \mod 17
$$

$$
= 8 \times 17 \mod 17
$$

$$
= 0 \mod 17
$$