Python | Easy to Understand
\nclass Solution:\n    def stoneGameIX(self, stones: List[int]) -> bool:\n        mod = {}\n        mod[0] = 0\n        mod[1] = 0\n        mod[2] = 0\n        
```\nclass Solution:\n    def stoneGameIX(self, stones: List[int]) -> bool:\n        mod = {}\n        mod[0] = 0\n        mod[1] = 0\n        mod[2] = 0\n        for i in stones:\n            mod[i%3] += 1\n        if(mod[0]%2==0):\n            if(min(mod[1],mod[2])==0):\n                return False\n            else:\n                return True\n        else:\n            if(abs(mod[1]-mod[2])>2):\n                return True\n            else:\n                return False\n```
[]