I could not think about how to prove that decimal expansion of a rational number of a rational number is eventually repeating.
Note that this question has to be proved using Pigeonhole principle only. So, don't close it.
While searching on internet I found this solution whose image I am posting. 
But I am unable to think about how does author writes this in third line of proof ->To compute the 10 place digit $a_1$ one computes $r_0$ ×10 = $a_1$ × n +$r_1$ .
Can someone please give explanation of this statement that why this must be true.
If you are struggling to understand some abstract statement first consider a concrete example.
For instance, set $m=17,n=7$. Then $\frac{m}{n}=\frac{17}{7}=2.428571428571...$.
So by division algorithm, you get $17=2\cdot7+3$. You can observe $2$ is the integer part and $3/7$ is the fractional part which is equal to $0.42857142857... $
what is the tenth place digit it is $4$ right? what is it? it is the integer part of $10* 0.42857142857... $ or in other words it is the integer part of $\frac{3\cdot10}{7}$
To get the integer part you multiply $3$ by $10$ an apply division algorithm. which gives you $30=4\cdot7+2$. You can proceed in this manner to get any $10^{-i}$th place digit.
Edit: Suppose $r_i=r_j$ for some $i\lt j$. Also, you know that $0\leq r_i \leq n-1$
Then by division algorithm you can find unique integers $a_{i+1},r_{i+1}$ where $0\leq r_{i+1} \leq n-1$ s.t $10\cdot r_i=a_{i+1}\cdot n+r_{i+1}$.
It follows from the uniqueness that $a_{i+1}=a_{j+1},r_{i+1}=r_{j+1}$