Count substrings whose characters are all distinct
Return how many non-empty contiguous substrings of a string contain no repeated character, in linear time.
No answer yet. Write the first one; the best answer gets endorsed.
Return how many non-empty contiguous substrings of a string contain no repeated character, in linear time.