Question: What is the probabilty that the sequence of digits 123 will appear in a nine digit long sequence.
To clarify: If you have some randomly generated nine digit sequence like 918273645, then what is the probability that the 123, will appear. (the digits 123 have to be consecutive)
I have thought about this problem for a while now, and it has proven to be more difficult than I initially thought.
This is what I have thought so far. First, one must see how many sets of three consecutive digits appear in the sequence. In the case of a nine digit sequence then there are 7 such sets.
So if your sequence is 102856285 then your 7 sets are
102, 028, 285, 856, 562, 628, 285
The chances that the string 123 matches with one of these sets is
My logic seems solid up to this point and then things get shaky.
Since we are given 7 sets then our chances that at least one matches is ??? BUT, I'm sure that must be wrong, because by that logic if we are given sets, then our probability would be one, and obviously it should always be less than one.
I am stuck. (I have some other ideas about how to approach it but I'll see what you guys have to say first,,, surely the solution must not be too complicated)