If a bit string contains {0, 1} only, having length 5 has no more than 2 ones in it. Then how many such bit strings are possible?
A. 14
B. 12
C. 15
D. 16
Answer:D
If a bit string contains {0, 1} only, having length 5 has no more than 2 ones in it. Then how many such bit strings are possible?
A. 14 B. 12 C. 15 D. 16
Explanation: The total strings are 1(having no one in it) +5(having 1 one in it) +10 (having 2 ones in it) = 16