arrow
arrow
arrow
A bit string of length four is generated at random. What is probability that it contains at least two consecutive 0 's given that first bit is 0?
Question

A bit string of length four is generated at random. What is probability that it contains at least two consecutive 0 's given that first bit is 0?

A.

​12\frac{1}{2}​​

B.

​516\frac{5}{16}​​

C.

​58\frac{5}{8}​​

D.

​14\frac{1}{4}​​

Correct option is C

We need to find the probability that a randomly generated bit string of length 4 contains at least two consecutive 0s, given that the first bit is 0.
Step 1: Determine the sample space
A bit string consists only of 0s and 1s.
Since the first bit is already given as 0, the string has the form 0xxx where each of the remaining three bits can independently be either 0 or 1. Therefore, the total number of possible bit strings is:
​23=82^3=8​​
The possible strings are:
0000,  0001,  0010,  0011,  0100,  0101,  0110,  0111
Step 2: Identify the favorable outcomes
We need strings containing at least two consecutive 0s.
“Consecutive” means that the two 0s must occur immediately next to each other, i.e., the string must contain the substring 00.
Let's examine each possibility:

  1. 0000 → contains 00 → Favorable
  2. 0001 → contains 00 → Favorable
  3. 0010 → contains 00 → Favorable
  4. 0011 → contains 00 → Favorable
  5. 0100 → contains 00 → Favorable
  6. 0101 → no 00 → Not favorable
  7. 0110 → no 00; the two 0s are separated by 11 → Not favorable
  8. 0111 → no 00 → Not favorable

Thus, the number of favorable outcomes is: 5
Step 3: Calculate the probability
Since all 8 strings are equally likely,
​P(at least two consecutive 0s∣first bit is 0)=Number of favorable outcomesTotal number of outcomesP(\text{at least two consecutive 0s}\mid\text{first bit is 0}) = \frac{\text{Number of favorable outcomes}} {\text{Total number of outcomes}}​​
​=58=\frac{5}{8}​​
Therefore,
​58\boxed{\frac{5}{8}}​​
Important note: The string 0110 does not contain consecutive 0s. Although it has two 0s, they are not adjacent.
Information Booster
1. Meaning of a Bit String: A bit can have only two possible values: 0 or 1
Therefore, a bit string of length n has: 2n2^n​ possible combinations.
For a four-bit string, there are: 24=162^4=16​ possible strings in total.
However, because the question specifies that the first bit is 0, only the remaining three bits are free to vary. Hence, the relevant sample space contains: 23=82^3=8​ strings.
2. Meaning of "At Least Two Consecutive 0s"
“At least two consecutive 0s” means that the string must contain at least one occurrence of 00.
For example:

  • 0001 → contains 00 → Yes
  • 0100 → contains 00 → Yes
  • 0110 → has two 0s, but they are separated → No

The 0s do not have to be exactly two; a string such as 0000 also qualifies because it contains multiple pairs of consecutive 0s.
Additional Knowledge
Conditional Probability
The phrase “given that the first bit is 0” means that we restrict our sample space to only those strings whose first bit is 0.
In general,
​P(A∣B)=P(A∩B)P(B)P(A\mid B)=\frac{P(A\cap B)}{P(B)}​​
Here:

  • A = the string contains at least two consecutive 0s.
  • B = the first bit is 0.

Rather than considering all 16 four-bit strings, we directly work with the 8 strings satisfying B.
Thus:
​P(A∣B)=58P(A\mid B)=\frac{5}{8}​​

Free Tests

Free
Must Attempt

Basics of Education: Pedagogy, Andragogy, and Hutagogy

languageIcon English
  • pdpQsnIcon10 Questions
  • pdpsheetsIcon20 Marks
  • timerIcon12 Mins
languageIcon English
Free
Must Attempt

UGC NET Paper 1 Mock Test 1

languageIcon English
  • pdpQsnIcon50 Questions
  • pdpsheetsIcon100 Marks
  • timerIcon60 Mins
languageIcon English
Free
Must Attempt

Basics of Education: Pedagogy, Andragogy, and Hutagogy

languageIcon English
  • pdpQsnIcon10 Questions
  • pdpsheetsIcon20 Marks
  • timerIcon12 Mins
languageIcon English

Similar Questions

test-prime-package

Access ‘UGC NET Computer Science’ Mock Tests with

  • 60000+ Mocks and Previous Year Papers
  • Unlimited Re-Attempts
  • Personalised Report Card
  • 500% Refund on Final Selection
  • Largest Community
students-icon
567k+ students have already unlocked exclusive benefits with Test Prime!

Similar Questions

Our Plans
Monthsup-arrow