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

On to step 1:
If we divide 7 by 31, we get 0 and a remainder of 7.
The next digit of our result is 0. 
Result so far: 0.0
Subtracting 0 from 7 leaves us with 7.
Fetch the next digit (7) from the dividend, attach it to 7 and continue: 77 / 31

On to step 2:
When dividing 77 by 31, we get 2 with a remainder of 15.
Put 2 as the next digit of the answer. 
Result so far: 2.0
Subtracting 62 from 77 leaves us with 15.
Bring next digit (7) of the dividend behind the 15 and repeat the process: 157 / 31

Advancing to step 3:
31 can be fit into 157 5 times, resulting in a remainder of 2.
Use 5 as the next digit of our solution. 
Result so far: 25.0
Deduct 155 from 157 and we're left with 2.
Grab the next digit (7) from the dividend, add it to 2, then carry on: 27 / 31

On to step 4:
If we divide 27 by 31, we get 0 and a remainder of 27.
Put 0 as the next digit of the answer. 
Result so far: 250.0
The remainder is 27 after subtracting 0 from 27.
Fetch the next digit (5) from the dividend, attach it to 27 and continue: 275 / 31

Going ahead to step 5:
275 divided by 31 is 8 with a remainder of 27.
The number 8 becomes the next digit in our result. 
Result so far: 2508.0
Deduct 248 from 275 and we're left with 27.
Grab the next digit (4) from the dividend, add it to 27, then carry on: 274 / 31

Going ahead to step 6:
The number 31 fits into 274 8 times, leaving a remainder of 26.
Use 8 as the next digit of our solution. 
Result so far: 25088.0
Subtracting 248 from 274 leaves us with 26.
Since there are no more digits in the dividend, we add a zero to the remainder making it 260, and continue the process.

Advancing to step 7:
260 divided by 31 is 8 with a remainder of 12.
Put 8 as the next digit of the answer. 
Result so far: 25088.8
If we subtract 248 from 260, we 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.

Step 8:
When dividing 120 by 31, we get 3 with a remainder of 27.
Put 3 as the next digit of the answer. 
Result so far: 25088.83
The remainder is 27 after subtracting 93 from 120.
Since there are no more digits in the dividend, we add a zero to the remainder making it 270, and continue the process.

Going ahead to step 9:
31 goes into 270 8 times with a remainder of 22.
Put 8 as the next digit of the answer. 
Result so far: 25088.838
The remainder is 22 after subtracting 248 from 270.
Since there are no more digits in the dividend, we add a zero to the remainder making it 220, and continue the process.

On to step 10:
31 can be fit into 220 7 times, resulting in a remainder of 3.
Put 7 as the next digit of the answer. 
Result so far: 25088.8387
Subtract 217 from 220 to get 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 11:
When dividing 30 by 31, we get 0 with a remainder of 30.
Write down 0 as next digit of the result. 
Result so far: 25088.8387
Subtract 0 from 30 to get 30.
Since there are no more digits in the dividend, we add a zero to the remainder making it 300, and continue the process.

Step 12:
31 goes into 300 9 times with a remainder of 21.
The next digit of our result is 9. 
Result so far: 25088.838709
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.

On to step 13:
When dividing 210 by 31, we get 6 with a remainder of 24.
Put 6 as the next digit of the answer. 
Result so far: 25088.8387096
Deduct 186 from 210 and we're left with 24.
Since there are no more digits in the dividend, we add a zero to the remainder making it 240, and continue the process.

Step 14:
If we divide 240 by 31, we get 7 and a remainder of 23.
Write down 7 as next digit of the result. 
Result so far: 25088.83870967
Subtract 217 from 240 to get 23.
Since there are no more digits in the dividend, we add a zero to the remainder making it 230, and continue the process.

The final outcome is 25088.83870967, with a leftover of 2.3e-08.