in reply to Preserving hash structure after subroutine call
use Data::Dumper; my %myhash = {}; build_hash(\%myhash); print Dumper(\%myhash); sub build_hash { my $href = shift; my %results = (1,2,3,4);; %{$href} = %results; # print Dumper($href); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Preserving hash structure after subroutine call
by Anonymous Monk on May 13, 2003 at 21:38 UTC |