Hackerrank - Palindrome Index Solution(click on raw)
Given a string of lowercase letters in the range ascii[a-z], determine a character that can be removed to make the string a palindrome. There may be more than one solution, but any will do. For example, if your string is "bcbc", you can either remove 'b' at index or 'c' at index . If the word is already a palindrome or there is no solution, return -1. Otherwise, return the index of a character to remove.
Function Description
Complete the palindromeIndex function in the editor below. It must return the index of the character to remove or .
palindromeIndex has the following parameter(s):