On Mon, Jan 25, 2010 at 10:28 PM, Gary Wright <gwtmp01 / mac.com> wrote:
>
> On Jan 25, 2010, at 2:24 PM, Glen Holcomb wrote:
>>
>> I'll play around with your solution. =A0I have the following:
>>
>> data =3D Hash.new { |l, k| l[k] =3D Hash.new { |l, k| l[k] =3D Hash.new =
{ |l, k|
>> l[k] =3D Hash.new([]) }}}
>
> I'm assuming you want 'infinite' depth. =A0Consider:
>
> default =3D lambda { |h,k| h[k] =3D Hash.new(&default) }
> top =3D Hash.new(&default)

The problem is that he wants the leaves of the hash to be arrays, and
not hashes.

Jesus.