Minimum Score to Make a String Subsequence
You're given two strings, s and t. You can delete any number of characters from t. The score of the resulting string is defined as follows: If no characters are removed, the score is 0. Otherwise, find the minimum and maximum indices of the removed characters. The score is then the difference between the maximum and minimum indices, plus one.
Your task is to determine the minimum possible score required to make t a subsequence of s.
Ada AI
I want to discuss a solution
Help me solve this
Give more examples
What's wrong with my code?
How to use 'for loop' in javascript?
javascript (node 13.12.0)