We're dividing 39940447 by 987 
Let's see how many times 987 fits into 39940447.

Moving on to step 1:
The number 987 fits into 3 0 times, leaving a remainder of 3.
Use 0 as the next digit of our solution. 
Result so far: 0.0
The remainder is 3 after subtracting 0 from 3.
Bring next digit (9) of the dividend behind the 3 and repeat the process: 39 / 987

Let's proceed to step 2:
39 divided by 987 is 0 with a remainder of 39.
The number 0 becomes the next digit in our result. 
Result so far: 0.0
Subtract 0 from 39 to get 39.
Take the next digit (9) from the dividend and append it to 39, then repeat: 399 / 987

Moving on to step 3:
If we divide 399 by 987, we get 0 and a remainder of 399.
Use 0 as the next digit of our solution. 
Result so far: 0.0
The remainder is 399 after subtracting 0 from 399.
Include the next digit (4) from the dividend after 399, then repeat: 3994 / 987

On to step 4:
987 can be fit into 3994 4 times, resulting in a remainder of 46.
The number 4 becomes the next digit in our result. 
Result so far: 4.0
If we take 3948 away from 3994, we end up with 46.
Grab the next digit (0) from the dividend, add it to 46, then carry on: 460 / 987

Moving on to step 5:
The number 987 fits into 460 0 times, leaving a remainder of 460.
Record the quotient 0 as the next digit in the result. 
Result so far: 40.0
Deduct 0 from 460 and we're left with 460.
Bring next digit (4) of the dividend behind the 460 and repeat the process: 4604 / 987

Moving on to step 6:
When dividing 4604 by 987, we get 4 with a remainder of 656.
Write down 4 as next digit of the result. 
Result so far: 404.0
If we take 3948 away from 4604, we end up with 656.
Grab the next digit (4) from the dividend, add it to 656, then carry on: 6564 / 987

On to step 7:
When dividing 6564 by 987, we get 6 with a remainder of 642.
Record the quotient 6 as the next digit in the result. 
Result so far: 4046.0
Subtract 5922 from 6564 to get 642.
Take the next digit (7) from the dividend and append it to 642, then repeat: 6427 / 987

On to step 8:
When dividing 6427 by 987, we get 6 with a remainder of 505.
Write down 6 as next digit of the result. 
Result so far: 40466.0
The remainder is 505 after subtracting 5922 from 6427.
Since there are no more digits in the dividend, we add a zero to the remainder making it 5050, and continue the process.

Advancing to step 9:
987 can be fit into 5050 5 times, resulting in a remainder of 115.
Use 5 as the next digit of our solution. 
Result so far: 40466.5
Deduct 4935 from 5050 and we're left with 115.
Since there are no more digits in the dividend, we add a zero to the remainder making it 1150, and continue the process.

On to step 10:
987 goes into 1150 1 times with a remainder of 163.
Write down 1 as next digit of the result. 
Result so far: 40466.51
If we take 987 away from 1150, we end up with 163.
Since there are no more digits in the dividend, we add a zero to the remainder making it 1630, and continue the process.

On to step 11:
When dividing 1630 by 987, we get 1 with a remainder of 643.
Record the quotient 1 as the next digit in the result. 
Result so far: 40466.511
Subtract 987 from 1630 to get 643.
Since there are no more digits in the dividend, we add a zero to the remainder making it 6430, and continue the process.

The quotient of the division is 40466.511, and the remainder is 0.0643.