Count character replacements needed to make string a palindrome
for (int i = 0; i &lt; Math.ceil(chars.length / 2); i++) {
      char currentChar = Character.toLowerCase(chars[i]);
      char oppositeChar = Character.toLowerCase(chars[chars.length - 1 - i]);



You'll get the identical answer from Math.floor

    for (int i = 0; i &lt; Math.floor(chars.length / 2.0); i++) {
      char currentChar = Character.toLowerCase(chars[i]);
      char oppositeChar = Character.toLowerCase(chars[chars.length - 1 - i]);


For one thing, you would get the integer result from the original since you were dividing two integers.  But even if you fix that, realize that both return the same answer.  Because when i == chars.length - 1 - i, the absolute value of the difference will always be zero.  And that case is the one that the second version does not do.  

    for (int i = 0; i &lt; chars.length / 2; i++) {
      char currentChar = Character.toLowerCase(chars[i]);
      char oppositeChar = Character.toLowerCase(chars[chars.length - 1 - i]);


This does the same thing through the magic of integer math which implicitly takes the floor for you.  

You can save some math by using two variables.  

    for (int i = 0, j = chars.length - 1; i &lt; j; i++, j--) {
      char currentChar = Character.toLowerCase(chars[i]);
      char oppositeChar = Character.toLowerCase(chars[j]);