We divide 1238782 by 399
We want to divide 1238782 by 399.

On to step 1:
When dividing 1 by 399, we get 0 with a remainder of 1.
Use 0 as the next digit of our solution. 
Result so far: 0.0
If we take 0 away from 1, we end up with 1.
Fetch the next digit (2) from the dividend, attach it to 1 and continue: 12 / 399

Step 2:
399 goes into 12 0 times with a remainder of 12.
The number 0 becomes the next digit in our result. 
Result so far: 0.0
If we subtract 0 from 12, we get 12.
Fetch the next digit (3) from the dividend, attach it to 12 and continue: 123 / 399

Moving on to step 3:
399 goes into 123 0 times with a remainder of 123.
The number 0 becomes the next digit in our result. 
Result so far: 0.0
If we take 0 away from 123, we end up with 123.
Grab the next digit (8) from the dividend, add it to 123, then carry on: 1238 / 399

Step 4:
If we divide 1238 by 399, we get 3 and a remainder of 41.
The number 3 becomes the next digit in our result. 
Result so far: 3.0
Subtracting 1197 from 1238 leaves us with 41.
Include the next digit (7) from the dividend after 41, then repeat: 417 / 399

Going ahead to step 5:
399 goes into 417 1 times with a remainder of 18.
Use 1 as the next digit of our solution. 
Result so far: 31.0
Subtract 399 from 417 to get 18.
Take the next digit (8) from the dividend and append it to 18, then repeat: 188 / 399

On to step 6:
188 divided by 399 is 0 with a remainder of 188.
The next digit of our result is 0. 
Result so far: 310.0
If we subtract 0 from 188, we get 188.
Include the next digit (2) from the dividend after 188, then repeat: 1882 / 399

Let's proceed to step 7:
When dividing 1882 by 399, we get 4 with a remainder of 286.
Use 4 as the next digit of our solution. 
Result so far: 3104.0
Subtract 1596 from 1882 to get 286.
Since there are no more digits in the dividend, we add a zero to the remainder making it 2860, and continue the process.

On to step 8:
2860 divided by 399 is 7 with a remainder of 67.
The next digit of our result is 7. 
Result so far: 3104.7
If we subtract 2793 from 2860, we get 67.
Since there are no more digits in the dividend, we add a zero to the remainder making it 670, and continue the process.

Advancing to step 9:
If we divide 670 by 399, we get 1 and a remainder of 271.
Write down 1 as next digit of the result. 
Result so far: 3104.71
Subtracting 399 from 670 leaves us with 271.
Since there are no more digits in the dividend, we add a zero to the remainder making it 2710, and continue the process.

On to step 10:
399 can be fit into 2710 6 times, resulting in a remainder of 316.
Record the quotient 6 as the next digit in the result. 
Result so far: 3104.716
Subtract 2394 from 2710 to get 316.
Since there are no more digits in the dividend, we add a zero to the remainder making it 3160, and continue the process.

Let's proceed to step 11:
399 can be fit into 3160 7 times, resulting in a remainder of 367.
Record the quotient 7 as the next digit in the result. 
Result so far: 3104.7167
If we take 2793 away from 3160, we end up with 367.
Since there are no more digits in the dividend, we add a zero to the remainder making it 3670, and continue the process.

Let's proceed to step 12:
399 can be fit into 3670 9 times, resulting in a remainder of 79.
The number 9 becomes the next digit in our result. 
Result so far: 3104.71679
The remainder is 79 after subtracting 3591 from 3670.
Since there are no more digits in the dividend, we add a zero to the remainder making it 790, and continue the process.

Let's proceed to step 13:
When dividing 790 by 399, we get 1 with a remainder of 391.
The next digit of our result is 1. 
Result so far: 3104.716791
Subtracting 399 from 790 leaves us with 391.
Since there are no more digits in the dividend, we add a zero to the remainder making it 3910, and continue the process.

Step 14:
When dividing 3910 by 399, we get 9 with a remainder of 319.
Write down 9 as next digit of the result. 
Result so far: 3104.7167919
The remainder is 319 after subtracting 3591 from 3910.
Since there are no more digits in the dividend, we add a zero to the remainder making it 3190, and continue the process.

Step 15:
The number 399 fits into 3190 7 times, leaving a remainder of 397.
Write down 7 as next digit of the result. 
Result so far: 3104.71679197
Subtract 2793 from 3190 to get 397.
Since there are no more digits in the dividend, we add a zero to the remainder making it 3970, and continue the process.

The final outcome is 3104.71679197, with a leftover of 3.97e-07.