in reply to hash of lists - hash of hashes

This is the best that I've managed so far:
while (($k, $lref) = each %HoL){ $HoL{$k}={map {$_,1} @$lref}; }
I tried to get something along the lines of the following bit of code to work but couldn't:
%HoL=map {map {$_,1} @HoL{$_}} keys %HoL;
I'm sure merlyn could blow this out of the water (and I hope he does, I'd love to see his solution... probably something really slick w/ 2 maps)

Replies are listed 'Best First'.
RE: Re: hash of lists - hash of hashes
by visnu (Sexton) on Jun 13, 2000 at 04:12 UTC
    oooh