GATE Computer ScienceHardGATE CS (PYQ pattern)

How many binary strings of length 10 contain no two consecutive 1s and also do not have 1 at both the first and the last position?

  1. A. 144
  2. B. 136
  3. C. 123
  4. D. 128

Correct answer: C. 123

Strings without 11 number F(12) = 144; those starting and ending with 1 (so 0 at positions 2 and 9, free middle of length 6 with no 11) number 21. The answer is 123.

More Theory of Computation questions

Exams that ask this topic