7. [55] Consider sequences $a$ of the form $a=\left(a_{1}, a_{2}, \ldots, a_{20}\right)$ such that each term $a_{i}$ is either 0 or 1 . For each such sequence $a$, we can produce a sequence $b=\left(b_{1}, b_{2}, \ldots, b_{20}\right)$, where
$$
b_{i}=\left\{\begin{array}{ll}
a_{i}+a_{i+1} & i=1 \\
a_{i-1}+a_{i}+a_{i+1} & 1<i<20 \\
a_{i-1}+a_{i} & i=20 .
\end{array}\right.
$$

How many sequences $b$ are there that can be produced by more than one distinct sequence $a$ ?
Answer:
64
Let the two sequences be $b$ and $\hat{b}$. Then, observe that given $a$, if $b_{1}=\hat{b}_{1}$ and $b_{2}=\hat{b}_{2}$, then $b=\hat{b}$ (since $a$ will uniquely determine the remaining elements in $b$ and $\hat{b}$ ). Thus, $b$ and $\hat{b}$ must start with $(1,0, \ldots)$ and $(0,1, \ldots)$, respectively (without loss of generality).
Note that $a_{3}$ is either 1 (in which case $b_{3}=\hat{b}_{3}=0$ ) or 2 (in which case $b_{3}=\hat{b}_{3}=1$ ). Moreover, $b_{4}, b_{5}$ must be the same as $b_{1}, b_{2}$ (and the same for $\hat{b}$ ) for the sequences to generate the same $a_{3}, a_{4}$. We can then pick $a_{6}, a_{9}, \ldots$.
Observe, that the last elements also have to be $(\ldots, 1,0)$ for $b$ and $(\ldots, 0,1)$ for $\hat{b}$. Thus, the answer is nonzero only for sequence lengths of $2(\bmod 3)$, in which case, our answer is $2^{k}$, where the length is $3 k+2$ (since we have two choices for every third element).
Here, since $N=20=3(6)+2$, the answer is $2^{6}=64$.