You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
What do you expect the result to be if the length of the substrings is zero?
There is no one right answer, but we expect you to output a number of empty strings:
one more than the length of the input string.
While not intuitive to everyone, this upholds the property that the number of substrings is one more than the length of the input string minus the length of the substrings.