Jump to content
BrainDen.com - Brain Teasers
  • 0


superprismatic
 Share

Question

1 answer to this question

Recommended Posts

  • 0

If we number the Fibonacci sequence: F(0) = 0, F(1) = 1, sequence is

0,1,1,2,3,5,8,...

call S(n) the Superprismatic count--number of binary strings without consecutive 1's.

S(n) = F(n+2)

When generating the strings of length n, you can prefix any n-1 string with "0", and any n-2 string with "10" and there aren't any others. (The n-2 strings prefixed with "00" are already taken care of)

What a cute problem! Thank you, Superprismatic!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...