We're dividing 400787 by 6 
We want to figure out the number of times 400787 can be divided by 6.

Let's proceed to step 1:
When dividing 4 by 6, we get 0 with a remainder of 4.
The number 0 becomes the next digit in our result. 
Result so far: 0.0
Subtract 0 from 4 to get 4.
Include the next digit (0) from the dividend after 4, then repeat: 40 / 6

Going ahead to step 2:
6 goes into 40 6 times with a remainder of 4.
The next digit of our result is 6. 
Result so far: 6.0
Subtracting 36 from 40 leaves us with 4.
Take the next digit (0) from the dividend and append it to 4, then repeat: 40 / 6

On to step 3:
The number 6 fits into 40 6 times, leaving a remainder of 4.
The number 6 becomes the next digit in our result. 
Result so far: 66.0
If we subtract 36 from 40, we get 4.
Grab the next digit (7) from the dividend, add it to 4, then carry on: 47 / 6

Let's proceed to step 4:
6 can be fit into 47 7 times, resulting in a remainder of 5.
Record the quotient 7 as the next digit in the result. 
Result so far: 667.0
Deduct 42 from 47 and we're left with 5.
Include the next digit (8) from the dividend after 5, then repeat: 58 / 6

Let's proceed to step 5:
The number 6 fits into 58 9 times, leaving a remainder of 4.
Use 9 as the next digit of our solution. 
Result so far: 6679.0
Subtracting 54 from 58 leaves us with 4.
Fetch the next digit (7) from the dividend, attach it to 4 and continue: 47 / 6

Moving on to step 6:
When dividing 47 by 6, we get 7 with a remainder of 5.
Write down 7 as next digit of the result. 
Result so far: 66797.0
If we take 42 away from 47, we end up 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.

Let's proceed to step 7:
6 goes into 50 8 times with a remainder of 2.
Write down 8 as next digit of the result. 
Result so far: 66797.8
Subtracting 48 from 50 leaves us with 2.
Since there are no more digits in the dividend, we add a zero to the remainder making it 20, and continue the process.

Advancing to step 8:
The number 6 fits into 20 3 times, leaving a remainder of 2.
The number 3 becomes the next digit in our result. 
Result so far: 66797.83
Subtract 18 from 20 to get 2.
Since there are no more digits in the dividend, we add a zero to the remainder making it 20, and continue the process.

Moving on to step 9:
The number 6 fits into 20 3 times, leaving a remainder of 2.
Record the quotient 3 as the next digit in the result. 
Result so far: 66797.833
If we take 18 away from 20, we end up with 2.
Since there are no more digits in the dividend, we add a zero to the remainder making it 20, and continue the process.

In conclusion, the division gives 66797.833 with a balance of 0.0002.