Let's divide 501238 by 2
Let's see how many times 2 fits into 501238.

Going ahead to step 1:
2 goes into 5 2 times with a remainder of 1.
Use 2 as the next digit of our solution. 
Result so far: 2.0
The remainder is 1 after subtracting 4 from 5.
Fetch the next digit (0) from the dividend, attach it to 1 and continue: 10 / 2

Moving on to step 2:
10 divided by 2 is 5 with a remainder of 0.
The next digit of our result is 5. 
Result so far: 25.0
Subtract 10 from 10 to get 0.
Fetch the next digit (1) from the dividend, attach it to 0 and continue: 1 / 2

On to step 3:
If we divide 1 by 2, we get 0 and a remainder of 1.
The next digit of our result is 0. 
Result so far: 250.0
Deduct 0 from 1 and we're left with 1.
Bring next digit (2) of the dividend behind the 1 and repeat the process: 12 / 2

Step 4:
When dividing 12 by 2, we get 6 with a remainder of 0.
Use 6 as the next digit of our solution. 
Result so far: 2506.0
Deduct 12 from 12 and we're left with 0.
Fetch the next digit (3) from the dividend, attach it to 0 and continue: 3 / 2

Going ahead to step 5:
3 divided by 2 is 1 with a remainder of 1.
Write down 1 as next digit of the result. 
Result so far: 25061.0
Subtracting 2 from 3 leaves us with 1.
Include the next digit (8) from the dividend after 1, then repeat: 18 / 2

Going ahead to step 6:
When dividing 18 by 2, we get 9 with a remainder of 0.
The next digit of our result is 9. 
Result so far: 250619.0
Subtracting 18 from 18 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.

Advancing to step 7:
The number 2 fits into 0 0 times, leaving a remainder of 0.
The next digit of our result is 0. 
Result so far: 250619.0
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.

Moving on to step 8:
2 goes into 0 0 times with a remainder of 0.
Write down 0 as next digit of the result. 
Result so far: 250619.0
If we take 0 away from 0, we end up 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.

Our division results in 250619.0 with a remaining 0.0.