Java | 100%
```\nclass Solution {\n    public int maxPower(String s) {\n        if(s.length()==0) return 0;\n        int n = s.length(), max = 1, curr = 1;\n        char pc
```\nclass Solution {\n    public int maxPower(String s) {\n        if(s.length()==0) return 0;\n        int n = s.length(), max = 1, curr = 1;\n        char pc = s.charAt(0);\n        for(int i = 1; i < n; i++){\n            curr = s.charAt(i) == s.charAt(i-1) ? curr + 1 : 1;\n            max = Math.max(curr, max);\n        }\n        return max;\n    }\n}
['Java']