Let's divide 662996 by 40
We're looking to find how many times 40 goes into 662996.

Advancing to step 1:
If we divide 6 by 40, we get 0 and a remainder of 6.
Put 0 as the next digit of the answer. 
Result so far: 0.0
The remainder is 6 after subtracting 0 from 6.
Bring next digit (6) of the dividend behind the 6 and repeat the process: 66 / 40

Advancing to step 2:
40 goes into 66 1 times with a remainder of 26.
Use 1 as the next digit of our solution. 
Result so far: 1.0
Deduct 40 from 66 and we're left with 26.
Fetch the next digit (2) from the dividend, attach it to 26 and continue: 262 / 40

Let's proceed to step 3:
If we divide 262 by 40, we get 6 and a remainder of 22.
The next digit of our result is 6. 
Result so far: 16.0
If we take 240 away from 262, we end up with 22.
Take the next digit (9) from the dividend and append it to 22, then repeat: 229 / 40

Let's proceed to step 4:
If we divide 229 by 40, we get 5 and a remainder of 29.
The number 5 becomes the next digit in our result. 
Result so far: 165.0
If we subtract 200 from 229, we get 29.
Fetch the next digit (9) from the dividend, attach it to 29 and continue: 299 / 40

Let's proceed to step 5:
When dividing 299 by 40, we get 7 with a remainder of 19.
Record the quotient 7 as the next digit in the result. 
Result so far: 1657.0
The remainder is 19 after subtracting 280 from 299.
Append the next digit (6) from the dividend to 19 and continue with: 196 / 40

On to step 6:
If we divide 196 by 40, we get 4 and a remainder of 36.
The number 4 becomes the next digit in our result. 
Result so far: 16574.0
If we take 160 away from 196, we end up with 36.
Since there are no more digits in the dividend, we add a zero to the remainder making it 360, and continue the process.

Advancing to step 7:
40 goes into 360 9 times with a remainder of 0.
Write down 9 as next digit of the result. 
Result so far: 16574.9
Subtracting 360 from 360 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.

Step 8:
When dividing 0 by 40, we get 0 with a remainder of 0.
The next digit of our result is 0. 
Result so far: 16574.9
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.

Step 9:
When dividing 0 by 40, we get 0 with a remainder of 0.
Use 0 as the next digit of our solution. 
Result so far: 16574.9
Deduct 0 from 0 and we're left 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.

After the division, we end up with 16574.9 and a remainder of 0.0.