From: Gavin Sinclair Date: 2004-07-13T15:18:58+09:00 Subject: Re: Ruby quickies and useful idioms Ian Caliban wrote: > I often find myself needing to instantiate a populated Hash, based on > the contents of two arrays, where the first contains what will become > the keys of the Hash and the second the values. Just curious: what sort of scenario necessitates that use? If there were a nice easy way to do that in Ruby, what would you like it to be called? i.e. a = [:x, :y, :z] b = [1, 2, 3] hash = # Fill me in! assert_equal({:x => 1, :y => 2, :z => 3}, hash) Cheers, Gavin