We divide 396347 by 18
The aim is to understand the frequency of 18 in 396347.

On to step 1:
When dividing 3 by 18, we get 0 with a remainder of 3.
Use 0 as the next digit of our solution. 
Result so far: 0.0
Subtracting 0 from 3 leaves us with 3.
Include the next digit (9) from the dividend after 3, then repeat: 39 / 18

Going ahead to step 2:
39 divided by 18 is 2 with a remainder of 3.
The next digit of our result is 2. 
Result so far: 2.0
Subtract 36 from 39 to get 3.
Bring next digit (6) of the dividend behind the 3 and repeat the process: 36 / 18

Advancing to step 3:
18 can be fit into 36 2 times, resulting in a remainder of 0.
The next digit of our result is 2. 
Result so far: 22.0
Deduct 36 from 36 and we're left with 0.
Include the next digit (3) from the dividend after 0, then repeat: 3 / 18

Going ahead to step 4:
The number 18 fits into 3 0 times, leaving a remainder of 3.
Use 0 as the next digit of our solution. 
Result so far: 220.0
The remainder is 3 after subtracting 0 from 3.
Bring next digit (4) of the dividend behind the 3 and repeat the process: 34 / 18

Step 5:
18 can be fit into 34 1 times, resulting in a remainder of 16.
The number 1 becomes the next digit in our result. 
Result so far: 2201.0
If we take 18 away from 34, we end up with 16.
Bring next digit (7) of the dividend behind the 16 and repeat the process: 167 / 18

On to step 6:
18 goes into 167 9 times with a remainder of 5.
Put 9 as the next digit of the answer. 
Result so far: 22019.0
If we take 162 away from 167, 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.

Going ahead to step 7:
50 divided by 18 is 2 with a remainder of 14.
Record the quotient 2 as the next digit in the result. 
Result so far: 22019.2
If we take 36 away from 50, we end up with 14.
Since there are no more digits in the dividend, we add a zero to the remainder making it 140, and continue the process.

Advancing to step 8:
If we divide 140 by 18, we get 7 and a remainder of 14.
Write down 7 as next digit of the result. 
Result so far: 22019.27
Deduct 126 from 140 and we're left with 14.
Since there are no more digits in the dividend, we add a zero to the remainder making it 140, and continue the process.

Step 9:
18 can be fit into 140 7 times, resulting in a remainder of 14.
The next digit of our result is 7. 
Result so far: 22019.277
Subtract 126 from 140 to get 14.
Since there are no more digits in the dividend, we add a zero to the remainder making it 140, and continue the process.

The quotient of the division is 22019.277, and the remainder is 0.0014.