A random bit string of length n is constructed by tossing a fair coin n times and setting a bit to 0 or 1 depending on outcomes head and tail, respectively. The probability that two such randomly generated strings are not identical is:
View worked solution
Answer: D
Let and be two randomly generated bit strings of length .
Since each bit is generated independently by tossing a fair coin, there are possible unique bit strings of length , each equally likely to be generated.
For the two strings to be identical (), whatever string is chosen for , the second string must match it exactly. Since there is only such matching string out of possibilities:
The probability that the two strings are not identical is the complement of this event:
Therefore, the correct option is D.
Free practice · Your answers on this page are not saved.
