How many bit strings of length ten either start with a 1 bit or end with two bits 00?
640
There are \(2^9\) strings starting with 1 and \(2^8\) ending with 00. Their intersection fixes three bits and has \(2^7\) strings. Inclusion–exclusion gives \(2^9+2^8-2^7=512+256-128=640\).
The general solution of recurrence relation
\(a_r-5a_{r-1}+6a_{r-2}=4^r,\ r\ge2\) is:
Every bounded sequence has
How many are there to place 8 indistinguishable balls into four distinguishable bins?