edited by
1,821 views

1 Answer

1 votes
1 votes
  1. $n + 1 (n$ prefixes for $n$ characters, plus the empty string$)$
  2. $n + 1 ($similar to $(a))$
  3.  $n - 1 (n$ prefixes for $n$ characters, minus the string itself$)$
  4. $n [1$ character substring$] + (n - 1) [2$ character substring$] + \dots + 1 = \dfrac{n (n + 1)}{2}.$  Add $1$ to include the empty substring.
  5. $\displaystyle{}\sum_{i=0}^{n} {^{n}C_{i}} = 2^{n}$, if you include the empty subsequence.
edited by

Related questions