We look at the division of 153715 by 40 
The aim is to understand the frequency of 40 in 153715.

Step 1:
When dividing 1 by 40, we get 0 with a remainder of 1.
The next digit of our result is 0. 
Result so far: 0.0
Subtracting 0 from 1 leaves us with 1.
Bring next digit (5) of the dividend behind the 1 and repeat the process: 15 / 40

Going ahead to step 2:
The number 40 fits into 15 0 times, leaving a remainder of 15.
Put 0 as the next digit of the answer. 
Result so far: 0.0
Subtract 0 from 15 to get 15.
Include the next digit (3) from the dividend after 15, then repeat: 153 / 40

On to step 3:
40 can be fit into 153 3 times, resulting in a remainder of 33.
Use 3 as the next digit of our solution. 
Result so far: 3.0
If we take 120 away from 153, we end up with 33.
Include the next digit (7) from the dividend after 33, then repeat: 337 / 40

Moving on to step 4:
40 goes into 337 8 times with a remainder of 17.
Put 8 as the next digit of the answer. 
Result so far: 38.0
If we take 320 away from 337, we end up with 17.
Fetch the next digit (1) from the dividend, attach it to 17 and continue: 171 / 40

Advancing to step 5:
171 divided by 40 is 4 with a remainder of 11.
The number 4 becomes the next digit in our result. 
Result so far: 384.0
Subtracting 160 from 171 leaves us with 11.
Include the next digit (5) from the dividend after 11, then repeat: 115 / 40

Advancing to step 6:
40 can be fit into 115 2 times, resulting in a remainder of 35.
Use 2 as the next digit of our solution. 
Result so far: 3842.0
Deduct 80 from 115 and we're left with 35.
Since there are no more digits in the dividend, we add a zero to the remainder making it 350, and continue the process.

Going ahead to step 7:
The number 40 fits into 350 8 times, leaving a remainder of 30.
The next digit of our result is 8. 
Result so far: 3842.8
The remainder is 30 after subtracting 320 from 350.
Since there are no more digits in the dividend, we add a zero to the remainder making it 300, and continue the process.

Advancing to step 8:
40 can be fit into 300 7 times, resulting in a remainder of 20.
The next digit of our result is 7. 
Result so far: 3842.87
Subtract 280 from 300 to get 20.
Since there are no more digits in the dividend, we add a zero to the remainder making it 200, and continue the process.

Step 9:
40 goes into 200 5 times with a remainder of 0.
Write down 5 as next digit of the result. 
Result so far: 3842.875
The remainder is 0 after subtracting 200 from 200.
Since there are no more digits in the dividend, we add a zero to the remainder making it 0, and continue the process.

Step 10:
When dividing 0 by 40, we get 0 with a remainder of 0.
Put 0 as the next digit of the answer. 
Result so far: 3842.875
If we subtract 0 from 0, we get 0.
Since there are no more digits in the dividend, we add a zero to the remainder making it 0, and continue the process.

On to step 11:
40 can be fit into 0 0 times, resulting in a remainder of 0.
The next digit of our result is 0. 
Result so far: 3842.875
If we take 0 away from 0, we end up with 0.
Since there are no more digits in the dividend, we add a zero to the remainder making it 0, and continue the process.

Our division results in 3842.875 with a remaining 0.0.