title: TypeError: can't convert String into Integer Error while using inject
body: <pre><code>[1,2,2,3].each.inject({}){|hash,e|
      hash[e.to_s]||=0
      hash[e.to_s]+=1
  }
  </code></pre>
  
  <p>It returns</p>
  
  <pre><code>TypeError: can't convert String into Integer.
  </code></pre>