Array Questions In Java Leetcode Longest Palindrome