title: TypeError: no implicit conversion of Symbol into Integer
body: <p>I encounter a strange problem when trying to alter values from a Hash. I have the following setup:</p>
  
  <pre><code>myHash = {
    company_name:"MyCompany", 
    street:"Mainstreet", 
    postcode:"1234", 
    city:"MyCity", 
    free_seats:"3"
  }
  
  def cleanup string
    string.titleize
  end
  
  def format
    output = Hash.new
    myHash.each do |item|
      item[:company_name] = cleanup(item[:company_name])
      item[:street] = cleanup(item[:street])
      output &lt;&lt; item
    end
  end
  </code></pre>
  
  <p>When I execute this code I get: "TypeError: no implicit conversion of Symbol into Integer" although the output of item[:company_name] is the expected string. What am I doing wrong?</p>