We divide 643562 by 40
The aim is to understand the frequency of 40 in 643562.

On to step 1:
40 goes into 6 0 times with a remainder of 6.
The number 0 becomes the next digit in our result. 
Result so far: 0.0
Subtract 0 from 6 to get 6.
Grab the next digit (4) from the dividend, add it to 6, then carry on: 64 / 40

Moving on to step 2:
If we divide 64 by 40, we get 1 and a remainder of 24.
Record the quotient 1 as the next digit in the result. 
Result so far: 1.0
The remainder is 24 after subtracting 40 from 64.
Append the next digit (3) from the dividend to 24 and continue with: 243 / 40

Moving on to step 3:
When dividing 243 by 40, we get 6 with a remainder of 3.
The next digit of our result is 6. 
Result so far: 16.0
Subtract 240 from 243 to get 3.
Include the next digit (5) from the dividend after 3, then repeat: 35 / 40

Moving on to step 4:
The number 40 fits into 35 0 times, leaving a remainder of 35.
Put 0 as the next digit of the answer. 
Result so far: 160.0
Subtracting 0 from 35 leaves us with 35.
Append the next digit (6) from the dividend to 35 and continue with: 356 / 40

Step 5:
If we divide 356 by 40, we get 8 and a remainder of 36.
Record the quotient 8 as the next digit in the result. 
Result so far: 1608.0
Subtract 320 from 356 to get 36.
Grab the next digit (2) from the dividend, add it to 36, then carry on: 362 / 40

Moving on to step 6:
When dividing 362 by 40, we get 9 with a remainder of 2.
Use 9 as the next digit of our solution. 
Result so far: 16089.0
The remainder is 2 after subtracting 360 from 362.
Since there are no more digits in the dividend, we add a zero to the remainder making it 20, and continue the process.

Going ahead to step 7:
40 can be fit into 20 0 times, resulting in a remainder of 20.
Put 0 as the next digit of the answer. 
Result so far: 16089.0
Deduct 0 from 20 and we're left with 20.
Since there are no more digits in the dividend, we add a zero to the remainder making it 200, and continue the process.

On to step 8:
If we divide 200 by 40, we get 5 and a remainder of 0.
Use 5 as the next digit of our solution. 
Result so far: 16089.05
Subtract 200 from 200 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.

Advancing to step 9:
0 divided by 40 is 0 with a remainder of 0.
Put 0 as the next digit of the answer. 
Result so far: 16089.05
Subtracting 0 from 0 leaves us 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:
The number 40 fits into 0 0 times, leaving a remainder of 0.
Put 0 as the next digit of the answer. 
Result so far: 16089.05
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.

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