Recursion - Find the options to make sequence of length of n without the sequence "11" - Binary numbers

32 Views Asked by At

I know this question exists here, I saw some other posts, but the problem, the answer is the same as my teacher.. I need to know why the answer is true Basically, I have to find the options of sequence of binary numbers without "$11$" with n length.
I tried this:
Let us first use the number $0$:
Then: there are $n-1$ numbers left, which means, for now: $a_n=a_{n-1}$
now, we use the number $1$:
Then: there are two choices:
a) we choose $0$: which means, we get left $n-2$ numbers, for now: $a_n=a_{n-1}+a_{n-2}$
b) we choose $1$: which is a problem, what am I supposed to do here? just "move on" and pass it? I know there are cases I have to subtract options, the question is, why am I not doing here minus $a_{n-2}$ on this option?