Module: Eneumann::Palindrome

Included in:
Integer, String
Defined in:
lib/eneumann/palindrome.rb,
lib/eneumann/palindrome/version.rb

Defined Under Namespace

Classes: Error

Constant Summary collapse

VERSION =
"0.2.2"

Instance Method Summary collapse

Instance Method Details

#palindrome?Boolean

Your code goes here… Returns true for a palindrome, false otherwise.

Returns:

  • (Boolean)


12
13
14
# File 'lib/eneumann/palindrome.rb', line 12

def palindrome?
  processed_content == processed_content.reverse
end