python3 easy solution beats 99%, clean code
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\nO(n^2)\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution:\n    def digitCount(self, num: str) -> bool:\n        # both time and space effiecent\n        arr = []\n        check = []\n        index = 0\n        for i in num:\n            temp = int(i)\n            arr.append(temp)\n            for j in range(temp):\n                check.append(index)\n            index +=1\n        check.sort()\n        arr.sort()\n        return  arr == check\n\n\n\n\n    \n```
['Python3']