edited by
328 views
0 votes
0 votes
How to write  recurrence relation for , possible binary sequence of size n ?
edited by

1 Answer

Best answer
2 votes
2 votes
here by size means by length n

so minimum 1 bit we can represent 0 or 1 total 2 elements

form 2 bit we can represent 00,01,10,11  total 4 element

so

T(n) = $\left\{\begin{matrix} 2T(n-1) & n>1 \\ 2 & n=1 \end{matrix}\right.$
selected by

Related questions

1 votes
1 votes
2 answers
1
srestha asked May 10, 2019
892 views
What is the solution of recurrence relation$T\left ( n \right )=T\left ( n-1 \right )+n$
1 votes
1 votes
1 answer
3
1 votes
1 votes
0 answers
4
srestha asked May 19, 2019
640 views
Let $A(n)$ denotes the number of $n$ bit binary strings which have no pair of consecutive $1’s.$ what will be recurrence relation for it and what will be it’s Time Co...