We look at the division of 395946 by 31 
We want to figure out the number of times 395946 can be divided by 31.

Let's proceed to step 1:
If we divide 3 by 31, we get 0 and a remainder of 3.
Put 0 as the next digit of the answer. 
Result so far: 0.0
If we subtract 0 from 3, we get 3.
Bring next digit (9) of the dividend behind the 3 and repeat the process: 39 / 31

Advancing to step 2:
39 divided by 31 is 1 with a remainder of 8.
The next digit of our result is 1. 
Result so far: 1.0
Subtracting 31 from 39 leaves us with 8.
Bring next digit (5) of the dividend behind the 8 and repeat the process: 85 / 31

Step 3:
The number 31 fits into 85 2 times, leaving a remainder of 23.
Write down 2 as next digit of the result. 
Result so far: 12.0
Deduct 62 from 85 and we're left with 23.
Append the next digit (9) from the dividend to 23 and continue with: 239 / 31

Step 4:
31 can be fit into 239 7 times, resulting in a remainder of 22.
The number 7 becomes the next digit in our result. 
Result so far: 127.0
Deduct 217 from 239 and we're left with 22.
Include the next digit (4) from the dividend after 22, then repeat: 224 / 31

On to step 5:
31 can be fit into 224 7 times, resulting in a remainder of 7.
Write down 7 as next digit of the result. 
Result so far: 1277.0
Subtracting 217 from 224 leaves us with 7.
Grab the next digit (6) from the dividend, add it to 7, then carry on: 76 / 31

Advancing to step 6:
If we divide 76 by 31, we get 2 and a remainder of 14.
Record the quotient 2 as the next digit in the result. 
Result so far: 12772.0
Deduct 62 from 76 and we're left with 14.
Since there are no more digits in the dividend, we add a zero to the remainder making it 140, and continue the process.

Going ahead to step 7:
The number 31 fits into 140 4 times, leaving a remainder of 16.
Record the quotient 4 as the next digit in the result. 
Result so far: 12772.4
The remainder is 16 after subtracting 124 from 140.
Since there are no more digits in the dividend, we add a zero to the remainder making it 160, and continue the process.

Let's proceed to step 8:
31 can be fit into 160 5 times, resulting in a remainder of 5.
Use 5 as the next digit of our solution. 
Result so far: 12772.45
Subtracting 155 from 160 leaves us with 5.
Since there are no more digits in the dividend, we add a zero to the remainder making it 50, and continue the process.

Step 9:
The number 31 fits into 50 1 times, leaving a remainder of 19.
Record the quotient 1 as the next digit in the result. 
Result so far: 12772.451
Deduct 31 from 50 and we're left with 19.
Since there are no more digits in the dividend, we add a zero to the remainder making it 190, and continue the process.

Advancing to step 10:
When dividing 190 by 31, we get 6 with a remainder of 4.
Record the quotient 6 as the next digit in the result. 
Result so far: 12772.4516
Subtract 186 from 190 to get 4.
Since there are no more digits in the dividend, we add a zero to the remainder making it 40, and continue the process.

Moving on to step 11:
31 can be fit into 40 1 times, resulting in a remainder of 9.
Use 1 as the next digit of our solution. 
Result so far: 12772.45161
If we subtract 31 from 40, we get 9.
Since there are no more digits in the dividend, we add a zero to the remainder making it 90, and continue the process.

On to step 12:
31 goes into 90 2 times with a remainder of 28.
The number 2 becomes the next digit in our result. 
Result so far: 12772.451612
Subtract 62 from 90 to get 28.
Since there are no more digits in the dividend, we add a zero to the remainder making it 280, and continue the process.

On to step 13:
280 divided by 31 is 9 with a remainder of 1.
Use 9 as the next digit of our solution. 
Result so far: 12772.4516129
Subtracting 279 from 280 leaves us with 1.
Since there are no more digits in the dividend, we add a zero to the remainder making it 10, and continue the process.

Moving on to step 14:
If we divide 10 by 31, we get 0 and a remainder of 10.
Use 0 as the next digit of our solution. 
Result so far: 12772.4516129
Deduct 0 from 10 and we're left with 10.
Since there are no more digits in the dividend, we add a zero to the remainder making it 100, and continue the process.

The final outcome is 12772.4516129, with a leftover of 1e-08.