:: Kotlin :: Solution
Code\n\nclass Solution {\n    fun stoneGameIX(stones: IntArray): Boolean {\n        var m = IntArray(3){ 0 }\n        stones.forEach{ m[it % 3]++ }\n\n        r
# Code\n```\nclass Solution {\n    fun stoneGameIX(stones: IntArray): Boolean {\n        var m = IntArray(3){ 0 }\n        stones.forEach{ m[it % 3]++ }\n\n        return if(m[0] % 2 == 0) m[1] > 0 && m[2] > 0 else Math.abs(m[1] - m[2]) > 2\n    }\n}\n```
['Kotlin']