find the longest repeating char in a sorted string
Anonymous
private static char mostRepeatingCharacter(char[] c) { int count = 0, max = 0; char ch = c[0]; for(int i = 0; i max ? count : max; } return ch; }
Check out your Company Bowl for anonymous work chats.