We look at the division of 878937 by 40 
Let's see how many times 40 fits into 878937.

On to step 1:
40 goes into 8 0 times with a remainder of 8.
Use 0 as the next digit of our solution. 
Result so far: 0.0
If we take 0 away from 8, we end up with 8.
Append the next digit (7) from the dividend to 8 and continue with: 87 / 40

Advancing to step 2:
40 goes into 87 2 times with a remainder of 7.
Record the quotient 2 as the next digit in the result. 
Result so far: 2.0
Deduct 80 from 87 and we're left with 7.
Include the next digit (8) from the dividend after 7, then repeat: 78 / 40

Step 3:
78 divided by 40 is 1 with a remainder of 38.
Record the quotient 1 as the next digit in the result. 
Result so far: 21.0
If we take 40 away from 78, we end up with 38.
Append the next digit (9) from the dividend to 38 and continue with: 389 / 40

On to step 4:
The number 40 fits into 389 9 times, leaving a remainder of 29.
The next digit of our result is 9. 
Result so far: 219.0
The remainder is 29 after subtracting 360 from 389.
Fetch the next digit (3) from the dividend, attach it to 29 and continue: 293 / 40

Step 5:
293 divided by 40 is 7 with a remainder of 13.
The next digit of our result is 7. 
Result so far: 2197.0
Subtract 280 from 293 to get 13.
Grab the next digit (7) from the dividend, add it to 13, then carry on: 137 / 40

Moving on to step 6:
137 divided by 40 is 3 with a remainder of 17.
Use 3 as the next digit of our solution. 
Result so far: 21973.0
Subtracting 120 from 137 leaves us with 17.
Since there are no more digits in the dividend, we add a zero to the remainder making it 170, and continue the process.

On to step 7:
When dividing 170 by 40, we get 4 with a remainder of 10.
Use 4 as the next digit of our solution. 
Result so far: 21973.4
Subtracting 160 from 170 leaves us with 10.
Since there are no more digits in the dividend, we add a zero to the remainder making it 100, and continue the process.

On to step 8:
40 goes into 100 2 times with a remainder of 20.
Use 2 as the next digit of our solution. 
Result so far: 21973.42
Subtracting 80 from 100 leaves us 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.

Step 9:
40 can be fit into 200 5 times, resulting in a remainder of 0.
Put 5 as the next digit of the answer. 
Result so far: 21973.425
Deduct 200 from 200 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.

Let's proceed to step 10:
0 divided by 40 is 0 with a remainder of 0.
Put 0 as the next digit of the answer. 
Result so far: 21973.425
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.

Advancing to step 11:
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: 21973.425
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.

The final outcome is 21973.425, with a leftover of 0.0.