Revision as of 18:21, 11 March 2009 by Kshen (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

You can do this by realizing that if the last letter is an a, b, or c you have a_n-1 choices for the first n-1 letters. However, if the last letter is d, you do not want cd or dd, so you can either have an a for the second letter or a b, and after that you have a_n-2 choices for strings. Therefore the recursion is a_n = 3 a_n-1 + 2 a_n-2

- Karen Midterm Practice Questions

Alumni Liaison

Ph.D. 2007, working on developing cool imaging technologies for digital cameras, camera phones, and video surveillance cameras.

Buyue Zhang