We divide 398187 by 54
The aim is to understand the frequency of 54 in 398187.

Advancing to step 1:
When dividing 3 by 54, we get 0 with a remainder of 3.
Record the quotient 0 as the next digit in the result. 
Result so far: 0.0
If we take 0 away from 3, we end up with 3.
Bring next digit (9) of the dividend behind the 3 and repeat the process: 39 / 54

Step 2:
54 can be fit into 39 0 times, resulting in a remainder of 39.
Put 0 as the next digit of the answer. 
Result so far: 0.0
The remainder is 39 after subtracting 0 from 39.
Grab the next digit (8) from the dividend, add it to 39, then carry on: 398 / 54

Step 3:
398 divided by 54 is 7 with a remainder of 20.
Record the quotient 7 as the next digit in the result. 
Result so far: 7.0
Deduct 378 from 398 and we're left with 20.
Grab the next digit (1) from the dividend, add it to 20, then carry on: 201 / 54

Let's proceed to step 4:
54 goes into 201 3 times with a remainder of 39.
Record the quotient 3 as the next digit in the result. 
Result so far: 73.0
The remainder is 39 after subtracting 162 from 201.
Append the next digit (8) from the dividend to 39 and continue with: 398 / 54

Advancing to step 5:
54 can be fit into 398 7 times, resulting in a remainder of 20.
The number 7 becomes the next digit in our result. 
Result so far: 737.0
Subtract 378 from 398 to get 20.
Fetch the next digit (7) from the dividend, attach it to 20 and continue: 207 / 54

On to step 6:
If we divide 207 by 54, we get 3 and a remainder of 45.
Use 3 as the next digit of our solution. 
Result so far: 7373.0
If we subtract 162 from 207, we get 45.
Since there are no more digits in the dividend, we add a zero to the remainder making it 450, and continue the process.

Step 7:
When dividing 450 by 54, we get 8 with a remainder of 18.
The next digit of our result is 8. 
Result so far: 7373.8
Subtracting 432 from 450 leaves us with 18.
Since there are no more digits in the dividend, we add a zero to the remainder making it 180, and continue the process.

Let's proceed to step 8:
180 divided by 54 is 3 with a remainder of 18.
The next digit of our result is 3. 
Result so far: 7373.83
The remainder is 18 after subtracting 162 from 180.
Since there are no more digits in the dividend, we add a zero to the remainder making it 180, and continue the process.

Advancing to step 9:
54 can be fit into 180 3 times, resulting in a remainder of 18.
Write down 3 as next digit of the result. 
Result so far: 7373.833
If we subtract 162 from 180, we get 18.
Since there are no more digits in the dividend, we add a zero to the remainder making it 180, and continue the process.

After the division, we end up with 7373.833 and a remainder of 0.0018.