Please solve the programming task below using a self-contained code snippet in a markdown code block.

You are given an integer n.
Each number from 1 to n is grouped according to the sum of its digits.
Return the number of groups that have the largest size.
 
Please complete the following python code precisely:
```python
class Solution:
    def countLargestGroup(self, n: int) -> int:
```