Find the even length palindrome with center points as i - 1 and i .
while ( ( l >= 0 ) and ( r < n ) and ( s [ l ] == s [ r ] ) ) : NEW_LINE INDENT ans2 += s [ l ] NEW_LINE l -= 1 NEW_LINE r += 1 NEW_LINE DEDENT v . append ( ans1 ) NEW_LINE v . append ( ans2 ) NEW_LINE ans = v [ 0 ] NEW_LINE