We look at the division of 158230 by 87 
The aim is to understand the frequency of 87 in 158230.

Going ahead to step 1:
1 divided by 87 is 0 with a remainder of 1.
Write down 0 as next digit of the result. 
Result so far: 0.0
Deduct 0 from 1 and we're left with 1.
Bring next digit (5) of the dividend behind the 1 and repeat the process: 15 / 87

Let's proceed to step 2:
15 divided by 87 is 0 with a remainder of 15.
The next digit of our result is 0. 
Result so far: 0.0
Subtract 0 from 15 to get 15.
Include the next digit (8) from the dividend after 15, then repeat: 158 / 87

Going ahead to step 3:
If we divide 158 by 87, we get 1 and a remainder of 71.
The next digit of our result is 1. 
Result so far: 1.0
If we take 87 away from 158, we end up with 71.
Grab the next digit (2) from the dividend, add it to 71, then carry on: 712 / 87

On to step 4:
87 goes into 712 8 times with a remainder of 16.
Record the quotient 8 as the next digit in the result. 
Result so far: 18.0
If we subtract 696 from 712, we get 16.
Fetch the next digit (3) from the dividend, attach it to 16 and continue: 163 / 87

Step 5:
87 goes into 163 1 times with a remainder of 76.
Write down 1 as next digit of the result. 
Result so far: 181.0
Deduct 87 from 163 and we're left with 76.
Fetch the next digit (0) from the dividend, attach it to 76 and continue: 760 / 87

Advancing to step 6:
When dividing 760 by 87, we get 8 with a remainder of 64.
Write down 8 as next digit of the result. 
Result so far: 1818.0
Subtracting 696 from 760 leaves us with 64.
Since there are no more digits in the dividend, we add a zero to the remainder making it 640, and continue the process.

Advancing to step 7:
When dividing 640 by 87, we get 7 with a remainder of 31.
Write down 7 as next digit of the result. 
Result so far: 1818.7
Subtracting 609 from 640 leaves us with 31.
Since there are no more digits in the dividend, we add a zero to the remainder making it 310, and continue the process.

On to step 8:
When dividing 310 by 87, we get 3 with a remainder of 49.
Write down 3 as next digit of the result. 
Result so far: 1818.73
If we subtract 261 from 310, we get 49.
Since there are no more digits in the dividend, we add a zero to the remainder making it 490, and continue the process.

On to step 9:
If we divide 490 by 87, we get 5 and a remainder of 55.
Put 5 as the next digit of the answer. 
Result so far: 1818.735
Subtract 435 from 490 to get 55.
Since there are no more digits in the dividend, we add a zero to the remainder making it 550, and continue the process.

Going ahead to step 10:
When dividing 550 by 87, we get 6 with a remainder of 28.
Record the quotient 6 as the next digit in the result. 
Result so far: 1818.7356
If we subtract 522 from 550, we get 28.
Since there are no more digits in the dividend, we add a zero to the remainder making it 280, and continue the process.

Advancing to step 11:
When dividing 280 by 87, we get 3 with a remainder of 19.
The number 3 becomes the next digit in our result. 
Result so far: 1818.73563
If we take 261 away from 280, we end up with 19.
Since there are no more digits in the dividend, we add a zero to the remainder making it 190, and continue the process.

Let's proceed to step 12:
When dividing 190 by 87, we get 2 with a remainder of 16.
The next digit of our result is 2. 
Result so far: 1818.735632
Subtracting 174 from 190 leaves us with 16.
Since there are no more digits in the dividend, we add a zero to the remainder making it 160, and continue the process.

On to step 13:
160 divided by 87 is 1 with a remainder of 73.
The number 1 becomes the next digit in our result. 
Result so far: 1818.7356321
If we take 87 away from 160, we end up with 73.
Since there are no more digits in the dividend, we add a zero to the remainder making it 730, and continue the process.

Going ahead to step 14:
When dividing 730 by 87, we get 8 with a remainder of 34.
The next digit of our result is 8. 
Result so far: 1818.73563218
Subtracting 696 from 730 leaves us with 34.
Since there are no more digits in the dividend, we add a zero to the remainder making it 340, and continue the process.

Our division results in 1818.73563218 with a remaining 3.4e-08.