in reply to Finding longest palindrome from a string
Nice puzzle, I offer my humble attempt
I tried a recursive one first which was fun but I had to do lots of work to cut the string into different slices so regex it is.
|
cnn, Thanks for the hint on code blanking.
Off by two error fixed in the for loop
Added .? in the middle to allow palindromes symetrical around a single character (borrowed that idea from ccn ;)
In Section
Seekers of Perl Wisdom