485. Total Distinctness of a String
The Distinctness of a string refers to the count of unique characters present in the string. For instance, the distinctness of the string "abbca" is 3 because it contains 3 distinct characters: 'a', 'b', and 'c'. Given a string s, the task is to calculate the total distinctness of all its substrings. A substring is a contiguous sequence of characters within the string.
A single line containing a string s.
An integer representing the total distinctness of the string.
1 <= N <= 10^5