876140 ÷ 40 
Let's see how many times 40 fits into 876140.

Step 1:
If we divide 8 by 40, we get 0 and a remainder of 8.
Put 0 as the next digit of the answer. 
Result so far: 0.0
Deduct 0 from 8 and we're left with 8.
Append the next digit (7) from the dividend to 8 and continue with: 87 / 40

Going ahead to step 2:
87 divided by 40 is 2 with a remainder of 7.
Write down 2 as next digit of the result. 
Result so far: 2.0
Deduct 80 from 87 and we're left with 7.
Append the next digit (6) from the dividend to 7 and continue with: 76 / 40

Step 3:
76 divided by 40 is 1 with a remainder of 36.
The number 1 becomes the next digit in our result. 
Result so far: 21.0
Subtracting 40 from 76 leaves us with 36.
Bring next digit (1) of the dividend behind the 36 and repeat the process: 361 / 40

Step 4:
The number 40 fits into 361 9 times, leaving a remainder of 1.
The next digit of our result is 9. 
Result so far: 219.0
Subtracting 360 from 361 leaves us with 1.
Include the next digit (4) from the dividend after 1, then repeat: 14 / 40

Advancing to step 5:
The number 40 fits into 14 0 times, leaving a remainder of 14.
Record the quotient 0 as the next digit in the result. 
Result so far: 2190.0
Deduct 0 from 14 and we're left with 14.
Bring next digit (0) of the dividend behind the 14 and repeat the process: 140 / 40

Moving on to step 6:
When dividing 140 by 40, we get 3 with a remainder of 20.
The number 3 becomes the next digit in our result. 
Result so far: 21903.0
The remainder is 20 after subtracting 120 from 140.
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 7:
200 divided by 40 is 5 with a remainder of 0.
The next digit of our result is 5. 
Result so far: 21903.5
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.

Advancing to step 8:
0 divided by 40 is 0 with a remainder of 0.
Put 0 as the next digit of the answer. 
Result so far: 21903.5
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 9:
If we divide 0 by 40, we get 0 and a remainder of 0.
Record the quotient 0 as the next digit in the result. 
Result so far: 21903.5
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.

The final result is 21903.5 with a remainder of 0.0.