507331 ÷ 31 
We want to figure out the number of times 507331 can be divided by 31.

Let's proceed to step 1:
If we divide 5 by 31, we get 0 and a remainder of 5.
Record the quotient 0 as the next digit in the result. 
Result so far: 0.0
Subtract 0 from 5 to get 5.
Fetch the next digit (0) from the dividend, attach it to 5 and continue: 50 / 31

On to step 2:
The number 31 fits into 50 1 times, leaving a remainder of 19.
Write down 1 as next digit of the result. 
Result so far: 1.0
Subtract 31 from 50 to get 19.
Grab the next digit (7) from the dividend, add it to 19, then carry on: 197 / 31

Step 3:
31 can be fit into 197 6 times, resulting in a remainder of 11.
Record the quotient 6 as the next digit in the result. 
Result so far: 16.0
Subtract 186 from 197 to get 11.
Take the next digit (3) from the dividend and append it to 11, then repeat: 113 / 31

Let's proceed to step 4:
The number 31 fits into 113 3 times, leaving a remainder of 20.
Use 3 as the next digit of our solution. 
Result so far: 163.0
If we take 93 away from 113, we end up with 20.
Fetch the next digit (3) from the dividend, attach it to 20 and continue: 203 / 31

Advancing to step 5:
31 goes into 203 6 times with a remainder of 17.
Use 6 as the next digit of our solution. 
Result so far: 1636.0
Subtract 186 from 203 to get 17.
Include the next digit (1) from the dividend after 17, then repeat: 171 / 31

Advancing to step 6:
31 can be fit into 171 5 times, resulting in a remainder of 16.
Write down 5 as next digit of the result. 
Result so far: 16365.0
The remainder is 16 after subtracting 155 from 171.
Since there are no more digits in the dividend, we add a zero to the remainder making it 160, and continue the process.

Advancing to step 7:
If we divide 160 by 31, we get 5 and a remainder of 5.
The next digit of our result is 5. 
Result so far: 16365.5
The remainder is 5 after subtracting 155 from 160.
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 8:
When dividing 50 by 31, we get 1 with a remainder of 19.
Write down 1 as next digit of the result. 
Result so far: 16365.51
The remainder is 19 after subtracting 31 from 50.
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 9:
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: 16365.516
If we subtract 186 from 190, we 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.

Going ahead to step 10:
When dividing 40 by 31, we get 1 with a remainder of 9.
Use 1 as the next digit of our solution. 
Result so far: 16365.5161
Subtract 31 from 40 to 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.

Moving on to step 11:
90 divided by 31 is 2 with a remainder of 28.
Record the quotient 2 as the next digit in the result. 
Result so far: 16365.51612
Deduct 62 from 90 and we're left with 28.
Since there are no more digits in the dividend, we add a zero to the remainder making it 280, and continue the process.

Going ahead to step 12:
280 divided by 31 is 9 with a remainder of 1.
Record the quotient 9 as the next digit in the result. 
Result so far: 16365.516129
Subtract 279 from 280 to get 1.
Since there are no more digits in the dividend, we add a zero to the remainder making it 10, and continue the process.

Going ahead to step 13:
31 goes into 10 0 times with a remainder of 10.
Record the quotient 0 as the next digit in the result. 
Result so far: 16365.516129
If we subtract 0 from 10, we get 10.
Since there are no more digits in the dividend, we add a zero to the remainder making it 100, and continue the process.

Step 14:
When dividing 100 by 31, we get 3 with a remainder of 7.
The next digit of our result is 3. 
Result so far: 16365.51612903
Subtracting 93 from 100 leaves us with 7.
Since there are no more digits in the dividend, we add a zero to the remainder making it 70, and continue the process.

In conclusion, the division gives 16365.51612903 with a balance of 7e-09.