40160995 divided by 665 
The aim is to understand the frequency of 665 in 40160995.

On to step 1:
665 goes into 4 0 times with a remainder of 4.
Put 0 as the next digit of the answer. 
Result so far: 0.0
Deduct 0 from 4 and we're left with 4.
Include the next digit (0) from the dividend after 4, then repeat: 40 / 665

On to step 2:
The number 665 fits into 40 0 times, leaving a remainder of 40.
Record the quotient 0 as the next digit in the result. 
Result so far: 0.0
The remainder is 40 after subtracting 0 from 40.
Bring next digit (1) of the dividend behind the 40 and repeat the process: 401 / 665

Step 3:
The number 665 fits into 401 0 times, leaving a remainder of 401.
Use 0 as the next digit of our solution. 
Result so far: 0.0
Deduct 0 from 401 and we're left with 401.
Fetch the next digit (6) from the dividend, attach it to 401 and continue: 4016 / 665

Moving on to step 4:
665 can be fit into 4016 6 times, resulting in a remainder of 26.
Record the quotient 6 as the next digit in the result. 
Result so far: 6.0
Subtracting 3990 from 4016 leaves us with 26.
Include the next digit (0) from the dividend after 26, then repeat: 260 / 665

Let's proceed to step 5:
When dividing 260 by 665, we get 0 with a remainder of 260.
Put 0 as the next digit of the answer. 
Result so far: 60.0
Subtracting 0 from 260 leaves us with 260.
Grab the next digit (9) from the dividend, add it to 260, then carry on: 2609 / 665

Step 6:
The number 665 fits into 2609 3 times, leaving a remainder of 614.
Put 3 as the next digit of the answer. 
Result so far: 603.0
Subtract 1995 from 2609 to get 614.
Bring next digit (9) of the dividend behind the 614 and repeat the process: 6149 / 665

Advancing to step 7:
665 can be fit into 6149 9 times, resulting in a remainder of 164.
Record the quotient 9 as the next digit in the result. 
Result so far: 6039.0
Subtracting 5985 from 6149 leaves us with 164.
Include the next digit (5) from the dividend after 164, then repeat: 1645 / 665

Advancing to step 8:
665 can be fit into 1645 2 times, resulting in a remainder of 315.
Use 2 as the next digit of our solution. 
Result so far: 60392.0
Subtract 1330 from 1645 to get 315.
Since there are no more digits in the dividend, we add a zero to the remainder making it 3150, and continue the process.

Step 9:
If we divide 3150 by 665, we get 4 and a remainder of 490.
Use 4 as the next digit of our solution. 
Result so far: 60392.4
If we take 2660 away from 3150, we end up with 490.
Since there are no more digits in the dividend, we add a zero to the remainder making it 4900, and continue the process.

Moving on to step 10:
When dividing 4900 by 665, we get 7 with a remainder of 245.
Write down 7 as next digit of the result. 
Result so far: 60392.47
Deduct 4655 from 4900 and we're left with 245.
Since there are no more digits in the dividend, we add a zero to the remainder making it 2450, and continue the process.

Going ahead to step 11:
The number 665 fits into 2450 3 times, leaving a remainder of 455.
The next digit of our result is 3. 
Result so far: 60392.473
Subtract 1995 from 2450 to get 455.
Since there are no more digits in the dividend, we add a zero to the remainder making it 4550, and continue the process.

Advancing to step 12:
The number 665 fits into 4550 6 times, leaving a remainder of 560.
Write down 6 as next digit of the result. 
Result so far: 60392.4736
The remainder is 560 after subtracting 3990 from 4550.
Since there are no more digits in the dividend, we add a zero to the remainder making it 5600, and continue the process.

Step 13:
If we divide 5600 by 665, we get 8 and a remainder of 280.
The next digit of our result is 8. 
Result so far: 60392.47368
If we take 5320 away from 5600, we end up with 280.
Since there are no more digits in the dividend, we add a zero to the remainder making it 2800, and continue the process.

Step 14:
When dividing 2800 by 665, we get 4 with a remainder of 140.
The next digit of our result is 4. 
Result so far: 60392.473684
Subtracting 2660 from 2800 leaves us with 140.
Since there are no more digits in the dividend, we add a zero to the remainder making it 1400, and continue the process.

Advancing to step 15:
665 goes into 1400 2 times with a remainder of 70.
Record the quotient 2 as the next digit in the result. 
Result so far: 60392.4736842
Deduct 1330 from 1400 and we're left with 70.
Since there are no more digits in the dividend, we add a zero to the remainder making it 700, and continue the process.

Advancing to step 16:
The number 665 fits into 700 1 times, leaving a remainder of 35.
The next digit of our result is 1. 
Result so far: 60392.47368421
If we subtract 665 from 700, we get 35.
Since there are no more digits in the dividend, we add a zero to the remainder making it 350, and continue the process.

The final result is 60392.47368421 with a remainder of 3.5e-08.