We look at the division of 639702 by 31 
The aim is to understand the frequency of 31 in 639702.

Advancing to step 1:
When dividing 6 by 31, we get 0 with a remainder of 6.
Write down 0 as next digit of the result. 
Result so far: 0.0
Deduct 0 from 6 and we're left with 6.
Take the next digit (3) from the dividend and append it to 6, then repeat: 63 / 31

Let's proceed to step 2:
When dividing 63 by 31, we get 2 with a remainder of 1.
Record the quotient 2 as the next digit in the result. 
Result so far: 2.0
The remainder is 1 after subtracting 62 from 63.
Bring next digit (9) of the dividend behind the 1 and repeat the process: 19 / 31

Step 3:
If we divide 19 by 31, we get 0 and a remainder of 19.
The next digit of our result is 0. 
Result so far: 20.0
The remainder is 19 after subtracting 0 from 19.
Fetch the next digit (7) from the dividend, attach it to 19 and continue: 197 / 31

Going ahead to step 4:
31 can be fit into 197 6 times, resulting in a remainder of 11.
The next digit of our result is 6. 
Result so far: 206.0
If we subtract 186 from 197, we get 11.
Take the next digit (0) from the dividend and append it to 11, then repeat: 110 / 31

Let's proceed to step 5:
The number 31 fits into 110 3 times, leaving a remainder of 17.
Write down 3 as next digit of the result. 
Result so far: 2063.0
Deduct 93 from 110 and we're left with 17.
Include the next digit (2) from the dividend after 17, then repeat: 172 / 31

Step 6:
The number 31 fits into 172 5 times, leaving a remainder of 17.
The number 5 becomes the next digit in our result. 
Result so far: 20635.0
If we take 155 away from 172, we end up with 17.
Since there are no more digits in the dividend, we add a zero to the remainder making it 170, and continue the process.

Step 7:
The number 31 fits into 170 5 times, leaving a remainder of 15.
The number 5 becomes the next digit in our result. 
Result so far: 20635.5
Subtracting 155 from 170 leaves us with 15.
Since there are no more digits in the dividend, we add a zero to the remainder making it 150, and continue the process.

Moving on to step 8:
The number 31 fits into 150 4 times, leaving a remainder of 26.
Write down 4 as next digit of the result. 
Result so far: 20635.54
The remainder is 26 after subtracting 124 from 150.
Since there are no more digits in the dividend, we add a zero to the remainder making it 260, and continue the process.

Moving on to step 9:
If we divide 260 by 31, we get 8 and a remainder of 12.
Put 8 as the next digit of the answer. 
Result so far: 20635.548
Subtract 248 from 260 to get 12.
Since there are no more digits in the dividend, we add a zero to the remainder making it 120, and continue the process.

Moving on to step 10:
120 divided by 31 is 3 with a remainder of 27.
The next digit of our result is 3. 
Result so far: 20635.5483
If we subtract 93 from 120, we get 27.
Since there are no more digits in the dividend, we add a zero to the remainder making it 270, and continue the process.

On to step 11:
31 can be fit into 270 8 times, resulting in a remainder of 22.
Put 8 as the next digit of the answer. 
Result so far: 20635.54838
If we take 248 away from 270, we end up with 22.
Since there are no more digits in the dividend, we add a zero to the remainder making it 220, and continue the process.

Step 12:
When dividing 220 by 31, we get 7 with a remainder of 3.
Put 7 as the next digit of the answer. 
Result so far: 20635.548387
If we take 217 away from 220, we end up with 3.
Since there are no more digits in the dividend, we add a zero to the remainder making it 30, and continue the process.

On to step 13:
When dividing 30 by 31, we get 0 with a remainder of 30.
Put 0 as the next digit of the answer. 
Result so far: 20635.548387
Subtracting 0 from 30 leaves us with 30.
Since there are no more digits in the dividend, we add a zero to the remainder making it 300, and continue the process.

On to step 14:
31 can be fit into 300 9 times, resulting in a remainder of 21.
Put 9 as the next digit of the answer. 
Result so far: 20635.54838709
Subtract 279 from 300 to get 21.
Since there are no more digits in the dividend, we add a zero to the remainder making it 210, and continue the process.

Our division results in 20635.54838709 with a remaining 2.1e-08.