Let's divide 396961 by 5
The aim is to understand the frequency of 5 in 396961.

Advancing to step 1:
The number 5 fits into 3 0 times, leaving a remainder of 3.
Write down 0 as next digit of the result. 
Result so far: 0.0
If we take 0 away from 3, we end up with 3.
Append the next digit (9) from the dividend to 3 and continue with: 39 / 5

Moving on to step 2:
The number 5 fits into 39 7 times, leaving a remainder of 4.
Put 7 as the next digit of the answer. 
Result so far: 7.0
Subtracting 35 from 39 leaves us with 4.
Include the next digit (6) from the dividend after 4, then repeat: 46 / 5

Moving on to step 3:
If we divide 46 by 5, we get 9 and a remainder of 1.
Use 9 as the next digit of our solution. 
Result so far: 79.0
The remainder is 1 after subtracting 45 from 46.
Include the next digit (9) from the dividend after 1, then repeat: 19 / 5

On to step 4:
The number 5 fits into 19 3 times, leaving a remainder of 4.
Use 3 as the next digit of our solution. 
Result so far: 793.0
If we subtract 15 from 19, we get 4.
Bring next digit (6) of the dividend behind the 4 and repeat the process: 46 / 5

Going ahead to step 5:
When dividing 46 by 5, we get 9 with a remainder of 1.
The number 9 becomes the next digit in our result. 
Result so far: 7939.0
Subtracting 45 from 46 leaves us with 1.
Take the next digit (1) from the dividend and append it to 1, then repeat: 11 / 5

Moving on to step 6:
If we divide 11 by 5, we get 2 and a remainder of 1.
The next digit of our result is 2. 
Result so far: 79392.0
Subtract 10 from 11 to get 1.
Since there are no more digits in the dividend, we add a zero to the remainder making it 10, and continue the process.

On to step 7:
5 can be fit into 10 2 times, resulting in a remainder of 0.
The number 2 becomes the next digit in our result. 
Result so far: 79392.2
Deduct 10 from 10 and we're left 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.

Going ahead to step 8:
5 goes into 0 0 times with a remainder of 0.
Use 0 as the next digit of our solution. 
Result so far: 79392.2
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.

Moving on to step 9:
5 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: 79392.2
If we subtract 0 from 0, we get 0.
Since there are no more digits in the dividend, we add a zero to the remainder making it 0, and continue the process.

Our division results in 79392.2 with a remaining 0.0.