104: Longest palindromic substring
Given a string
, return the longest palindromic substring
of a given string
A
palindrome
is astring
that reads the same backward as forward. For instance,level
,baab
Example 1
Input: abac
Output: aba
Example 2
Input: acdbba
Output: bb
Helpful article