@@ -0,0 +1,550 @@
+public class Solution %7B%0A  public int longestPalindrome(String s) %7B%0A    // count each occurance of a letter%0A    int%5B%5D letters = new int%5B58%5D;%0A%0A    for (int i = 0; i %3C s.length(); i++) %7B%0A      letters%5Bs.charAt(i) - 'A'%5D++;%0A    %7D%0A%0A    int counter = 0;%0A    boolean isOdd;%0A%0A    for (int i = 0; i %3C 58; i++) %7B%0A      if (letters%5Bi%5D %25 2 == 0) %7B%0A        counter += letters%5Bi%5D;%0A      %7D%0A      else %7B%0A        counter += letters%5Bi%5D - 1;%0A        isOdd    = true;%0A      %7D%0A    %7D%0A%0A%0A    if (isOdd) %7B%0A      return counter + longest + 1;%0A    %7D%0A%0A    return counter;%0A  %7D%0A%7D%0A

solved longestPalindrome