ashwood_palindrome 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9c2ad9277a0dea3153a5ca473347e0123e0598e0020dd2fc6875c908bcc713a3
4
- data.tar.gz: 75cc7283582e15b3c078b90c1b0102b6d276606931a4c6cb6ba1543816b45c69
3
+ metadata.gz: fdd7c41d9f9e32b78fe8e692d5fb1b35c95fc74f65118344582921bc81f7286d
4
+ data.tar.gz: f43944da268557c86914558af7cbe8e8f616b677fa210823456ee5bdd2824ece
5
5
  SHA512:
6
- metadata.gz: c6ead040d17fa8a6411b61ff7fe862798b52fc23cbc373dde3e393f3b8075ebe9ba0d850c6116345b355f591119c61a4d993785a2eeb07d80f3960e4220a7ab5
7
- data.tar.gz: c645d9ae63f59c007969478b64d14242fabc0b04aaa3d8e88393ef655fdaee91e6e6810b75bbadacc7968975bfa2051085389b5ce26a0828aa183e8d321d5164
6
+ metadata.gz: 65b693861ec9b537c585a5be270ba9419a0c6ed41a8ac8bfcd5ce2a9d694ac750d06c6bc867e75a4d4cce2cd36ff0ca8912a8bb0b9a3e7056ba511c8678f0777
7
+ data.tar.gz: e6eaf58c8858946e1fb67ddae2e18c456ca56ea914ba9cbf720b95ade0ca3178db34d5bc3a764023159518d03187351f6a4a21d52622d47157fcf90a992b88ad
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ashwood_palindrome (0.1.0)
4
+ ashwood_palindrome (0.2.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -1,3 +1,3 @@
1
1
  module AshwoodPalindrome
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
@@ -1,6 +1,6 @@
1
1
  require "ashwood_palindrome/version"
2
2
 
3
- class String
3
+ module AshwoodPalindrome
4
4
 
5
5
  def palindrome?
6
6
  processed_content == processed_content.reverse
@@ -9,6 +9,14 @@ class String
9
9
  private
10
10
 
11
11
  def processed_content
12
- self.scan(/[a-z]/i).join.downcase
12
+ self.to_s.scan(/[a-z0-9]/i).join.downcase
13
13
  end
14
14
  end
15
+
16
+ class String
17
+ include AshwoodPalindrome
18
+ end
19
+
20
+ class Integer
21
+ include AshwoodPalindrome
22
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ashwood_palindrome
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rosalynn