muzafar_palindrome 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 495071f35022646adea7bfbec29db17366bb56092f401e3b9808ddcc9c2093cd
4
- data.tar.gz: 8d2ac137d427f5f5eb357bd44c6b531a2976aae8dc44251660308f82dd83f4ea
3
+ metadata.gz: '076232750083742b5d4d5984c78811b0a36b8df3ccf5a237c1078cfdbe73204a'
4
+ data.tar.gz: 642ec47048357628daaa135cf27dcd430467ef9c2c4d333c5f7934084ea5c5ff
5
5
  SHA512:
6
- metadata.gz: ef18b967a4051d220ae70478de6e29e702d266a558969b55aee9f4865bd2f273944e8a903a128a86079c65b81582a66921ba01302fdfbe828a90ad987a02b4a1
7
- data.tar.gz: d674f42b370c4a05c05aa23f066eb67e360cca6de22fd0c8e4d3f7c738ac5f3e06ba039cdcb1255cd01b143c91183929abff9bd26577f242dddf18c3a29f478d
6
+ metadata.gz: cee9d1763817b14185709bc69f86c580b24837039f3b5bb128165a0b0b3eb7d5109980ea7706febb8259732078cbf51bf4767cb9076c5d348667880a023e7b4f
7
+ data.tar.gz: 25d1c738cc6d1072fa590f4bd90d6d9d0112a134dbc4b1939af48337633c20304ffec3294aa3c3892b5bba5d7f41c28a02cf61736a2852911763492be0f92313
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- muzafar_palindrome (0.1.0)
4
+ muzafar_palindrome (0.2.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -1,3 +1,3 @@
1
1
  module MuzafarPalindrome
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
@@ -1,7 +1,6 @@
1
1
  require "muzafar_palindrome/version"
2
2
 
3
- # Creating a module with functionality
4
- class String
3
+ module MuzafarPalindrome
5
4
 
6
5
  # Returns true for a palindrome. False otherwise
7
6
  def palindrome?
@@ -13,6 +12,15 @@ class String
13
12
 
14
13
  # Processes content for a palindrome detection.
15
14
  def processed_content
16
- scan(/[a-z]/i).join.downcase
15
+ to_s.scan(/[a-z\d]/i).join.downcase
17
16
  end
18
17
  end
18
+
19
+ # Creating a module with functionality
20
+ class String
21
+ include MuzafarPalindrome
22
+ end
23
+
24
+ class Integer
25
+ include MuzafarPalindrome
26
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: muzafar_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
  - Muzafar Ahmed