7stud -- wrote in post #1090536:
>
> 1) The block does not create the hash.   If you look at the block:
>
> Hash.new { |hash, key| hash[key] = [] }
>

Agreed.  Since we went from a simple:

hash = Hash.new  # no argument to new

to

hash = Hash.new { |hash, key| hash[key] = [] }  # block as argument to
new

I just wanted to understand how the block supplied the argument to new.
Done!

Thanks for the examples,

-- 
Posted via http://www.ruby-forum.com/.