easy solution
Intuitionuse n2ApproachComplexity
Time complexity:

Space complexity:
Code
# Intuition
<!-- Describe your first thoughts on how to solve this problem. -->
use n2 

# Approach
<!-- Describe your approach to solving the problem. -->

# Complexity
- Time complexity:
<!-- Add your time complexity here, e.g. $$O(n)$$ -->

- Space complexity:
<!-- Add your space complexity here, e.g. $$O(n)$$ -->

# Code
```python3 []
class Solution:
    def numberOfSubstrings(self, s: str, k: int) -> int:
        c = Counter()
        res = 0
        #{a: 2}
        #{a: 2, b: 1}
        for i in range(len(s)):
            c.clear()
            biggest = 0
            for j in range(i, len(s)):
                c[s[j]] += 1
                if c[s[j]] >= biggest:
                    biggest = c[s[j]]
                if biggest >= k:
                    res += 1
        return res

```
['Python3']