We're dividing 31871 by 58 
We're looking to find how many times 58 goes into 31871.

Going ahead to step 1:
When dividing 3 by 58, we get 0 with a remainder of 3.
Write down 0 as next digit of the result. 
Result so far: 0.0
Subtract 0 from 3 to get 3.
Grab the next digit (1) from the dividend, add it to 3, then carry on: 31 / 58

Advancing to step 2:
The number 58 fits into 31 0 times, leaving a remainder of 31.
Put 0 as the next digit of the answer. 
Result so far: 0.0
Deduct 0 from 31 and we're left with 31.
Grab the next digit (8) from the dividend, add it to 31, then carry on: 318 / 58

Let's proceed to step 3:
58 can be fit into 318 5 times, resulting in a remainder of 28.
The next digit of our result is 5. 
Result so far: 5.0
The remainder is 28 after subtracting 290 from 318.
Bring next digit (7) of the dividend behind the 28 and repeat the process: 287 / 58

Moving on to step 4:
58 can be fit into 287 4 times, resulting in a remainder of 55.
The next digit of our result is 4. 
Result so far: 54.0
If we subtract 232 from 287, we get 55.
Fetch the next digit (1) from the dividend, attach it to 55 and continue: 551 / 58

Step 5:
58 can be fit into 551 9 times, resulting in a remainder of 29.
Use 9 as the next digit of our solution. 
Result so far: 549.0
Subtracting 522 from 551 leaves us with 29.
Since there are no more digits in the dividend, we add a zero to the remainder making it 290, and continue the process.

Advancing to step 6:
58 goes into 290 5 times with a remainder of 0.
Use 5 as the next digit of our solution. 
Result so far: 549.5
The remainder is 0 after subtracting 290 from 290.
Since there are no more digits in the dividend, we add a zero to the remainder making it 0, and continue the process.

Let's proceed to step 7:
0 divided by 58 is 0 with a remainder of 0.
Use 0 as the next digit of our solution. 
Result so far: 549.5
Subtract 0 from 0 to get 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:
58 can be fit into 0 0 times, resulting in a remainder of 0.
Record the quotient 0 as the next digit in the result. 
Result so far: 549.5
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.

The quotient of the division is 549.5, and the remainder is 0.0.