Let's divide 474855 by 40
The aim is to understand the frequency of 40 in 474855.

Step 1:
When dividing 4 by 40, we get 0 with a remainder of 4.
Record the quotient 0 as the next digit in the result. 
Result so far: 0.0
If we subtract 0 from 4, we get 4.
Grab the next digit (7) from the dividend, add it to 4, then carry on: 47 / 40

Let's proceed to step 2:
If we divide 47 by 40, we get 1 and a remainder of 7.
The next digit of our result is 1. 
Result so far: 1.0
If we take 40 away from 47, we end up with 7.
Grab the next digit (4) from the dividend, add it to 7, then carry on: 74 / 40

On to step 3:
When dividing 74 by 40, we get 1 with a remainder of 34.
Record the quotient 1 as the next digit in the result. 
Result so far: 11.0
If we subtract 40 from 74, we get 34.
Grab the next digit (8) from the dividend, add it to 34, then carry on: 348 / 40

On to step 4:
40 can be fit into 348 8 times, resulting in a remainder of 28.
The number 8 becomes the next digit in our result. 
Result so far: 118.0
If we subtract 320 from 348, we get 28.
Take the next digit (5) from the dividend and append it to 28, then repeat: 285 / 40

Going ahead to step 5:
285 divided by 40 is 7 with a remainder of 5.
The number 7 becomes the next digit in our result. 
Result so far: 1187.0
If we subtract 280 from 285, we get 5.
Fetch the next digit (5) from the dividend, attach it to 5 and continue: 55 / 40

Advancing to step 6:
40 can be fit into 55 1 times, resulting in a remainder of 15.
Put 1 as the next digit of the answer. 
Result so far: 11871.0
Deduct 40 from 55 and we're left 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.

Let's proceed to step 7:
The number 40 fits into 150 3 times, leaving a remainder of 30.
The number 3 becomes the next digit in our result. 
Result so far: 11871.3
Deduct 120 from 150 and we're left 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.

Step 8:
40 can be fit into 300 7 times, resulting in a remainder of 20.
The number 7 becomes the next digit in our result. 
Result so far: 11871.37
If we subtract 280 from 300, we 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.

Let's proceed to step 9:
The number 40 fits into 200 5 times, leaving a remainder of 0.
Use 5 as the next digit of our solution. 
Result so far: 11871.375
If we take 200 away from 200, 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.

Going ahead to step 10:
40 goes into 0 0 times with a remainder of 0.
Write down 0 as next digit of the result. 
Result so far: 11871.375
Subtract 0 from 0 to 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.

Let's proceed to step 11:
The number 40 fits into 0 0 times, leaving a remainder of 0.
The number 0 becomes the next digit in our result. 
Result so far: 11871.375
Deduct 0 from 0 and we're left 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.

After the division, we end up with 11871.375 and a remainder of 0.0.