title: Calling self.send iteratively on a hash argument to initialize()
body: <p>I'm trying to understand the following Ruby code.</p>
  
  <p>It looks like <code>attrs</code> is a hash that gets passed as an argument with a default value of an empty hash.</p>
  
  <p>Then <code>attrs.each</code> iterates over the key, value pairs in the hash (<code>|k,v|</code>).</p>
  
  <p>What effect is achieved by calling <code>self.send</code> on the elements of the key value pair during this iteration?</p>
  
  <pre><code>def initialize(attrs = {}, *args)
    super(*args)
    attrs.each do |k,v|
      self.send "#{k}=", v
    end
  end
  </code></pre>