Count Distinct Substrings Leetcode 1501 Superior