As per the Ruby documentation,
string.count(character_set1,character_set2)first takes the
character_set1 and character_set2 and then counts the number of times
character from the resulting intersection occurs in string.
a = ‘hooooooooooll’
puts a.count “lo” “o”
displays 10 in irb but displays 12 in Ruby 1.9. Why?