We're dividing 40009258 by 870 
Let's see how many times 870 fits into 40009258.

Moving on to step 1:
When dividing 4 by 870, we get 0 with a remainder of 4.
Use 0 as the next digit of our solution. 
Result so far: 0.0
Deduct 0 from 4 and we're left with 4.
Take the next digit (0) from the dividend and append it to 4, then repeat: 40 / 870

Let's proceed to step 2:
If we divide 40 by 870, we get 0 and a remainder of 40.
Put 0 as the next digit of the answer. 
Result so far: 0.0
If we take 0 away from 40, we end up with 40.
Take the next digit (0) from the dividend and append it to 40, then repeat: 400 / 870

Let's proceed to step 3:
The number 870 fits into 400 0 times, leaving a remainder of 400.
Write down 0 as next digit of the result. 
Result so far: 0.0
The remainder is 400 after subtracting 0 from 400.
Grab the next digit (0) from the dividend, add it to 400, then carry on: 4000 / 870

Step 4:
If we divide 4000 by 870, we get 4 and a remainder of 520.
Write down 4 as next digit of the result. 
Result so far: 4.0
The remainder is 520 after subtracting 3480 from 4000.
Include the next digit (9) from the dividend after 520, then repeat: 5209 / 870

On to step 5:
The number 870 fits into 5209 5 times, leaving a remainder of 859.
The number 5 becomes the next digit in our result. 
Result so far: 45.0
The remainder is 859 after subtracting 4350 from 5209.
Grab the next digit (2) from the dividend, add it to 859, then carry on: 8592 / 870

Moving on to step 6:
When dividing 8592 by 870, we get 9 with a remainder of 762.
Put 9 as the next digit of the answer. 
Result so far: 459.0
If we subtract 7830 from 8592, we get 762.
Include the next digit (5) from the dividend after 762, then repeat: 7625 / 870

Going ahead to step 7:
When dividing 7625 by 870, we get 8 with a remainder of 665.
The next digit of our result is 8. 
Result so far: 4598.0
The remainder is 665 after subtracting 6960 from 7625.
Grab the next digit (8) from the dividend, add it to 665, then carry on: 6658 / 870

Step 8:
870 can be fit into 6658 7 times, resulting in a remainder of 568.
Write down 7 as next digit of the result. 
Result so far: 45987.0
Subtract 6090 from 6658 to get 568.
Since there are no more digits in the dividend, we add a zero to the remainder making it 5680, and continue the process.

Advancing to step 9:
5680 divided by 870 is 6 with a remainder of 460.
The number 6 becomes the next digit in our result. 
Result so far: 45987.6
Subtract 5220 from 5680 to get 460.
Since there are no more digits in the dividend, we add a zero to the remainder making it 4600, and continue the process.

Step 10:
If we divide 4600 by 870, we get 5 and a remainder of 250.
Use 5 as the next digit of our solution. 
Result so far: 45987.65
Subtracting 4350 from 4600 leaves us with 250.
Since there are no more digits in the dividend, we add a zero to the remainder making it 2500, and continue the process.

Let's proceed to step 11:
When dividing 2500 by 870, we get 2 with a remainder of 760.
Use 2 as the next digit of our solution. 
Result so far: 45987.652
If we subtract 1740 from 2500, we get 760.
Since there are no more digits in the dividend, we add a zero to the remainder making it 7600, and continue the process.

Advancing to step 12:
The number 870 fits into 7600 8 times, leaving a remainder of 640.
The number 8 becomes the next digit in our result. 
Result so far: 45987.6528
Subtract 6960 from 7600 to get 640.
Since there are no more digits in the dividend, we add a zero to the remainder making it 6400, and continue the process.

Going ahead to step 13:
The number 870 fits into 6400 7 times, leaving a remainder of 310.
The number 7 becomes the next digit in our result. 
Result so far: 45987.65287
Subtract 6090 from 6400 to get 310.
Since there are no more digits in the dividend, we add a zero to the remainder making it 3100, and continue the process.

On to step 14:
If we divide 3100 by 870, we get 3 and a remainder of 490.
Record the quotient 3 as the next digit in the result. 
Result so far: 45987.652873
If we take 2610 away from 3100, we end up with 490.
Since there are no more digits in the dividend, we add a zero to the remainder making it 4900, and continue the process.

Going ahead to step 15:
When dividing 4900 by 870, we get 5 with a remainder of 550.
Use 5 as the next digit of our solution. 
Result so far: 45987.6528735
Subtract 4350 from 4900 to get 550.
Since there are no more digits in the dividend, we add a zero to the remainder making it 5500, and continue the process.

Step 16:
5500 divided by 870 is 6 with a remainder of 280.
The next digit of our result is 6. 
Result so far: 45987.65287356
If we subtract 5220 from 5500, we get 280.
Since there are no more digits in the dividend, we add a zero to the remainder making it 2800, and continue the process.

After the division, we end up with 45987.65287356 and a remainder of 2.8e-07.