Asked by akash
                Q 8: Count the number of 01-strings with following constraints.
(b) The length is 8. Number of 1s is 3 more than number of 0s.
(c) The length is 9. Number of 1s is 3 more than number of 0s.
            
            
        (b) The length is 8. Number of 1s is 3 more than number of 0s.
(c) The length is 9. Number of 1s is 3 more than number of 0s.
Answers
                    Answered by
            MathMate
            
    Assuming question asks 
(b) The length is 8. Number of 1s is <i>at lease</i> 3 more than number of 0s.
(c) The length is 9. Number of 1s is <i>at lease</i> 3 more than number of 0s.
For length n, let
n0=number of zero bits
n1=number of one bits
and
n0+n1=n
(b)
For case n=8
situations where n1-n0≥3 are
{(8,0),(7,1),(6,2)}
with corresponding number of occurrences
{C(8,0),C(8,1),C(8,2)}={1,8,28}
[where C(n,r)=n!/(r!(n-r)!)]
so the total number is 37.
You can work out (c) in a similar way. Post if you wish, to check your answer.
For deep learning, suggest you to attempt to generalize the question to n-bit string, where n1-n0≥d
    
(b) The length is 8. Number of 1s is <i>at lease</i> 3 more than number of 0s.
(c) The length is 9. Number of 1s is <i>at lease</i> 3 more than number of 0s.
For length n, let
n0=number of zero bits
n1=number of one bits
and
n0+n1=n
(b)
For case n=8
situations where n1-n0≥3 are
{(8,0),(7,1),(6,2)}
with corresponding number of occurrences
{C(8,0),C(8,1),C(8,2)}={1,8,28}
[where C(n,r)=n!/(r!(n-r)!)]
so the total number is 37.
You can work out (c) in a similar way. Post if you wish, to check your answer.
For deep learning, suggest you to attempt to generalize the question to n-bit string, where n1-n0≥d
                    Answered by
            MathMate
            
    * least
    
                                                    There are no AI answers yet. The ability to request AI answers is coming soon!
                                            
                Submit Your Answer
We prioritize human answers over AI answers.
If you are human, and you can answer this question, please submit your answer.