Given a string of arbitrary length, write a perl program that will print out the palindrome(s) of longest length in the string. Assume there are no special characters, so "!c aba c!" would be considered a palindrome; also, in "abcbb", "bcb" would be considered a palindrome. Assume the string is coming in via STDIN.
This is actually a nice clever problem. I'm sure MJD could solve this while typing one-handed during a television commercial break, but I know that I had to think for at least five or ten minutes before getting a decent solution.
However, as if to completely spit in the face of this challenge, a Perl Monastery monk known only as BUU has decided to post the question openly, without any reference to the job posting. And as a result, got a lot of clever solutions, more clever than his first attempt.
It took another clever monk to figure out what was going on. Thank goodness for the eyes of Limbic~Region.
Look, I know times may be desparate and all, but to resort to cheating... that really frosts me.