Listen "Count A+B+C+ Subsequences"
Episode Synopsis
1. You are given a string str.
2. You are required to calculate and print the count of subsequences of the nature a+b+c+.
For abbc -> there are 3 subsequences. abc, abc, abbc
For abcabc -> there are 7 subsequences. abc, abc, abbc, aabc, abcc, abc, abc.
Input Format
A string str
Output Format
count of subsequences of the nature a+b+c+
Constraints
0 < str.length <= 10
Sample Input
abcabc
Sample Output
7
2. You are required to calculate and print the count of subsequences of the nature a+b+c+.
For abbc -> there are 3 subsequences. abc, abc, abbc
For abcabc -> there are 7 subsequences. abc, abc, abbc, aabc, abcc, abc, abc.
Input Format
A string str
Output Format
count of subsequences of the nature a+b+c+
Constraints
0 < str.length <= 10
Sample Input
abcabc
Sample Output
7
More episodes of the podcast algodextrous
Maximum Sum Non Adjacent Elements
07/08/2021
Count Encodings
23/07/2021
Arrange Buildings
23/07/2021
Count Binary Strings
03/07/2021
Fractional Knapsack
31/05/2021
Unbounded Knapsack
31/05/2021
Zero One Knapsack
30/05/2021
Coin Change Permutations
30/05/2021
Coin Change Combination
28/05/2021
ZARZA We are Zarza, the prestigious firm behind major projects in information technology.