class String
Magician's extensions to the String
class.
Public Instance Methods
palindrome?()
click to toggle source
Returns true if the string is a palindrome (meaning it is the same forward and backward).
@return [Boolean] true if the string is a palindrome
# File lib/magician/string.rb, line 8 def palindrome? eql? reverse end