[LeetCode] Count the Number of Good Subsequences

1 · · Jan. 31, 2023, 5:32 a.m.
2539. Count the Number of Good Subsequences A subsequence of a string is good if it is not empty and the frequency of each one of its characters is the same. Given a string s, return the number of good subsequences of s. Since the answer may be too large, return it modulo 109 + 7. A subsequence is a string that can be derived from another string by deleting some or no characters without changing the order of the remaining characters. ...