This is a problem of finding losngest palindromic substring in a given string.