understandable
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)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\n    public boolean winnerOfGame(String colors) {\n        int aCnt=0, bCnt=0;\n        int aTemp=0, bTemp=0;\n\n        for(int i=0;i<colors.length();i++)\n        {\n            char c = colors.charAt(i);\n            if(c==\'A\')\n            {\n                bTemp=0;\n                aTemp+=1;\n                if(aTemp>=3)\n                {\n                    aCnt+=1;\n                }\n            }\n            else\n            {\n                aTemp=0;\n                bTemp+=1;\n                if(bTemp>=3)\n                {\n                    bCnt+=1;\n                }\n            }\n        }\n        return aCnt>bCnt;\n    }\n}\n```
['Java']