Beefy Boxes and Bandwidth Generously Provided by pair Networks vroom
go ahead... be a heretic
 
PerlMonks  

Re: Palindrome array

by karlgoethebier (Deacon)
on Dec 29, 2012 at 19:35 UTC ( #1010843=note: print w/ replies, xml ) Need Help??


in reply to Palindrome array

BTW, why array? I just cheated this from Re^2: palindrome using regular expressions...

#!/usr/bin/perl + use strict; use warnings; my $palindrome = 'lagerregal'; my $check = reverse $palindrome; print "yes\n" if $check eq $palindrome; $palindrome='xamax'; $check = reverse $palindrome; print "still yes\n" if $check eq $palindrome; __END__

Regards, Karl

«The Crux of the Biscuit is the Apostrophe»


Comment on Re: Palindrome array
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1010843]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (5)
As of 2014-04-19 20:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (483 votes), past polls