We divide 398157 by 24
The aim is to understand the frequency of 24 in 398157.

On to step 1:
The number 24 fits into 3 0 times, leaving a remainder of 3.
Write down 0 as next digit of the result. 
Result so far: 0.0
The remainder is 3 after subtracting 0 from 3.
Fetch the next digit (9) from the dividend, attach it to 3 and continue: 39 / 24

Moving on to step 2:
24 can be fit into 39 1 times, resulting in a remainder of 15.
Use 1 as the next digit of our solution. 
Result so far: 1.0
If we take 24 away from 39, we end up with 15.
Fetch the next digit (8) from the dividend, attach it to 15 and continue: 158 / 24

Let's proceed to step 3:
If we divide 158 by 24, we get 6 and a remainder of 14.
Put 6 as the next digit of the answer. 
Result so far: 16.0
Subtract 144 from 158 to get 14.
Take the next digit (1) from the dividend and append it to 14, then repeat: 141 / 24

Step 4:
If we divide 141 by 24, we get 5 and a remainder of 21.
Record the quotient 5 as the next digit in the result. 
Result so far: 165.0
Subtracting 120 from 141 leaves us with 21.
Take the next digit (5) from the dividend and append it to 21, then repeat: 215 / 24

Moving on to step 5:
When dividing 215 by 24, we get 8 with a remainder of 23.
Put 8 as the next digit of the answer. 
Result so far: 1658.0
Subtract 192 from 215 to get 23.
Append the next digit (7) from the dividend to 23 and continue with: 237 / 24

Going ahead to step 6:
237 divided by 24 is 9 with a remainder of 21.
Use 9 as the next digit of our solution. 
Result so far: 16589.0
Subtracting 216 from 237 leaves us with 21.
Since there are no more digits in the dividend, we add a zero to the remainder making it 210, and continue the process.

Going ahead to step 7:
If we divide 210 by 24, we get 8 and a remainder of 18.
Write down 8 as next digit of the result. 
Result so far: 16589.8
Deduct 192 from 210 and we're left 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.

On to step 8:
The number 24 fits into 180 7 times, leaving a remainder of 12.
Write down 7 as next digit of the result. 
Result so far: 16589.87
Subtracting 168 from 180 leaves us with 12.
Since there are no more digits in the dividend, we add a zero to the remainder making it 120, and continue the process.

Let's proceed to step 9:
120 divided by 24 is 5 with a remainder of 0.
The next digit of our result is 5. 
Result so far: 16589.875
Subtracting 120 from 120 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.

Let's proceed to step 10:
If we divide 0 by 24, we get 0 and a remainder of 0.
Record the quotient 0 as the next digit in the result. 
Result so far: 16589.875
The remainder is 0 after subtracting 0 from 0.
Since there are no more digits in the dividend, we add a zero to the remainder making it 0, and continue the process.

Going ahead to step 11:
24 can be fit into 0 0 times, resulting in a remainder of 0.
The number 0 becomes the next digit in our result. 
Result so far: 16589.875
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 final result is 16589.875 with a remainder of 0.0.