We're dividing 38866 by 40 
We're looking to find how many times 40 goes into 38866.

Step 1:
3 divided by 40 is 0 with a remainder of 3.
Use 0 as the next digit of our solution. 
Result so far: 0.0
Subtract 0 from 3 to get 3.
Include the next digit (8) from the dividend after 3, then repeat: 38 / 40

Moving on to step 2:
If we divide 38 by 40, we get 0 and a remainder of 38.
Use 0 as the next digit of our solution. 
Result so far: 0.0
Subtracting 0 from 38 leaves us with 38.
Take the next digit (8) from the dividend and append it to 38, then repeat: 388 / 40

Moving on to step 3:
388 divided by 40 is 9 with a remainder of 28.
Put 9 as the next digit of the answer. 
Result so far: 9.0
Subtracting 360 from 388 leaves us with 28.
Take the next digit (6) from the dividend and append it to 28, then repeat: 286 / 40

Step 4:
When dividing 286 by 40, we get 7 with a remainder of 6.
Put 7 as the next digit of the answer. 
Result so far: 97.0
If we subtract 280 from 286, we get 6.
Bring next digit (6) of the dividend behind the 6 and repeat the process: 66 / 40

Step 5:
40 goes into 66 1 times with a remainder of 26.
The next digit of our result is 1. 
Result so far: 971.0
If we subtract 40 from 66, we get 26.
Since there are no more digits in the dividend, we add a zero to the remainder making it 260, and continue the process.

On to step 6:
260 divided by 40 is 6 with a remainder of 20.
The next digit of our result is 6. 
Result so far: 971.6
Deduct 240 from 260 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.

Moving on to step 7:
The number 40 fits into 200 5 times, leaving a remainder of 0.
The next digit of our result is 5. 
Result so far: 971.65
If we take 200 away from 200, we end up 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.

Moving on to step 8:
When dividing 0 by 40, we get 0 with a remainder of 0.
Write down 0 as next digit of the result. 
Result so far: 971.65
If we take 0 away from 0, we end up 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 9:
40 goes into 0 0 times with a remainder of 0.
Put 0 as the next digit of the answer. 
Result so far: 971.65
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.

Our division results in 971.65 with a remaining 0.0.