Question: In given three string str1, str2 and str3. Write a complement function to find the smallest sub-sequence in str1 which contains all the characters in

In given three string str1, str2 and str3. Write a complement function to find the smallest sub-sequence in str1 which contains all the characters in str2 and but not those in str3.

Step by Step Solution

3.45 Rating (161 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

def smallestsubsequencestr1 str2 str3 Count occurrences of characters in str2 and str3 countstr2 cou... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Data Structures Algorithms Questions!