Chance of guessing 5 out of 8 letters in sequence

combinatoricspermutations

Everybody guessed or copied a word with 8 letters. • If someone had
mutations at 3 of 8 positions from my word, there was a 1 chance
238,659 that they did not copy (they have written down 8-letter words
with 3 different letters just by chance). • What if the class has 238,
659 people in it? • Then, even if everyone came up with their word
randomly (and are therefore not related to each other) we would expect
someone to have 3 mutations off my word, simply by chance.

That is an analogy given by my bioinformatics teacher but I have no idea where 238,659 is from.

I looked at permutation,
P(n,r) = P(26,8)
= 6.2999E + 10

Is the probability of guessing all 8 letters correctly in sequence I think.

So the chances of guessing 5 out of 8 correctly in sequence is a permutation or combination and can someone throw up the equation/formula or more importantly what is 238,659?

Edit: My Professor is a very intelligent woman from China but her English is not so good. I posted on the course forum asking where 238,659 comes from so hopefully she will clarify everything regarding cases, etc etc. In the meanwhile, I thought there might be a simple explanation based on a few simple assumptions but I guess not.

Best Answer

I was able to reverse engineer what the solution, based on the number 238,659. The key issue is:
What constitutes a valid password?

Primary answer is :
Letters only, not case sensitive. So there are 26 different characters that can be used.

The OP made the natural presumption that letters may not be repeated. Using the OP's presumption, I could not reverse engineer the answer.

I then explored the opposite presumption:
Letters may be repeated in the password. This presumption ended up explaining 238,659.

The number of possible passwords is $D = (26)^8.$

There are $F = \binom{8}{3} = 56$ choices, for which 3 of the 8 letters will be wrong.

The # of ways that these 3 letters can be wrong is $N = (25)^3$.

Therefore, the chances of getting exactly 3 wrong characters out of the 8 are:

$$P = F \times \frac{N}{D} = \frac{56 \times (25)^3}{(26)^8}.$$

$P$ is approximately

$$\frac{1}{238659.5024}.$$

Related Question