palindrome detection palindrome

2

Write a function with a single string parameter and a boolean return value. The function should return true iff the string is a palindrome character-wise.

Alternatively, write a program that reads a string from standard input and writes 1/0 to standard output depending on whether the string is palindrome or not.

The code itself should be a palindrome. The structure of the code visually documents what the code is about.

Since this is all about beauty of code, the code with the most votes wins.

Erel Segal-Halevi

Posted 2014-01-29T15:09:54.057

Reputation: 1 885

Question was closed 2014-01-29T15:34:55.807

@KendallFrey you are right... I mistakenly searched for palyndrome with y. – Erel Segal-Halevi – 2014-01-29T15:13:06.727

1Would adding another constraint make the question unique enough? I notice that most of the solutions to the other problem use comments. I think it would be interesting to see a challenge where comments are forbidden. – Josh – 2014-01-29T15:20:23.117

@Josh good point, but I see the duplicate question already has some very nice answers without using comments. – Erel Segal-Halevi – 2014-01-29T15:27:32.037

Maybe mirroring, without using comments? - ( -> ), [ -> ], etc. – eithed – 2014-01-29T16:51:40.803

No answers