242287 divided by 31 
The aim is to understand the frequency of 31 in 242287.

On to step 1:
When dividing 2 by 31, we get 0 with a remainder of 2.
Record the quotient 0 as the next digit in the result. 
Result so far: 0.0
Deduct 0 from 2 and we're left with 2.
Fetch the next digit (4) from the dividend, attach it to 2 and continue: 24 / 31

On to step 2:
31 goes into 24 0 times with a remainder of 24.
The next digit of our result is 0. 
Result so far: 0.0
Subtracting 0 from 24 leaves us with 24.
Take the next digit (2) from the dividend and append it to 24, then repeat: 242 / 31

Advancing to step 3:
31 goes into 242 7 times with a remainder of 25.
Record the quotient 7 as the next digit in the result. 
Result so far: 7.0
If we take 217 away from 242, we end up with 25.
Bring next digit (2) of the dividend behind the 25 and repeat the process: 252 / 31

Step 4:
252 divided by 31 is 8 with a remainder of 4.
Write down 8 as next digit of the result. 
Result so far: 78.0
If we take 248 away from 252, we end up with 4.
Fetch the next digit (8) from the dividend, attach it to 4 and continue: 48 / 31

Going ahead to step 5:
48 divided by 31 is 1 with a remainder of 17.
The number 1 becomes the next digit in our result. 
Result so far: 781.0
The remainder is 17 after subtracting 31 from 48.
Take the next digit (7) from the dividend and append it to 17, then repeat: 177 / 31

Step 6:
177 divided by 31 is 5 with a remainder of 22.
The next digit of our result is 5. 
Result so far: 7815.0
If we subtract 155 from 177, we get 22.
Since there are no more digits in the dividend, we add a zero to the remainder making it 220, and continue the process.

Going ahead to step 7:
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: 7815.7
Deduct 217 from 220 and we're left 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.

Moving on to step 8:
31 goes into 30 0 times with a remainder of 30.
The number 0 becomes the next digit in our result. 
Result so far: 7815.7
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.

Going ahead to step 9:
When dividing 300 by 31, we get 9 with a remainder of 21.
The next digit of our result is 9. 
Result so far: 7815.709
If we take 279 away from 300, we end up with 21.
Since there are no more digits in the dividend, we add a zero to the remainder making it 210, and continue the process.

Going ahead to step 10:
31 can be fit into 210 6 times, resulting in a remainder of 24.
Use 6 as the next digit of our solution. 
Result so far: 7815.7096
If we take 186 away from 210, we end up 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.

Moving on to step 11:
31 goes into 240 7 times with a remainder of 23.
The next digit of our result is 7. 
Result so far: 7815.70967
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.

Advancing to step 12:
31 goes into 230 7 times with a remainder of 13.
The number 7 becomes the next digit in our result. 
Result so far: 7815.709677
If we take 217 away from 230, we end up with 13.
Since there are no more digits in the dividend, we add a zero to the remainder making it 130, and continue the process.

Our division results in 7815.709677 with a remaining 1.3e-06.