c++ simple solution
\tclass Solution {\n\tpublic:\n\t\tint maxPower(string s) {\n\t\t\tint maxlength = 1;\n\t\t\tint len = 1;\n\t\t\tfor(int i = 1; i < s.length(); i++){\n\t\t\t\ti
\tclass Solution {\n\tpublic:\n\t\tint maxPower(string s) {\n\t\t\tint maxlength = 1;\n\t\t\tint len = 1;\n\t\t\tfor(int i = 1; i < s.length(); i++){\n\t\t\t\tif(s[i] != s[i-1]) len = 1;\n\t\t\t\telse len++;\n\t\t\t\tmaxlength = max(len,maxlength);\n\t\t\t}\n\t\t\treturn maxlength;\n\t\t}\n\t};
['C']