http://qs321.pair.com?node_id=382606


in reply to Finding longest palindrome from a string

Here is my try,

sub deibyz { my $match; while(/.*?(.+)(.?)((??{reverse$1})).*?/g){ $match = $1.$2.$3 if length($1.$2.$3)>length($match); } $match; }