My brain is not that clear today...
longestPalindrome substring added. Got stuck for a long time.