Class: Hash
- Inherits:
-
Object
- Object
- Hash
- Defined in:
- lib/ext/hash.rb
Instance Method Summary collapse
Instance Method Details
#word_count ⇒ Object
2 3 4 5 6 7 8 |
# File 'lib/ext/hash.rb', line 2 def word_count count = 0 self.each_pair do |key, value| count += value.to_s.word_count end count end |