Hello Wagner-David, Saturday, November 03, 2001, Wagner-David <[EMAIL PROTECTED]> wrote:
WD> Here is one shot, though I changed some of the constants: WD> #!perl -w my %h1 = ("one" => 1, "two" => 2, "three" => 3); my %h2 = ("four" => 4, "five" => 5, "six" => 6); WD> my %h3 = (); WD> mergehash( \%h1, \%h2, \%h3); WD> sub mergehash { WD> my ( $h1, $h2, $h3) = @_; WD> foreach my $MyKey1 ( keys %{$h1} ) { WD> $h3->{$MyKey1} = $h1->{$MyKey1}; WD> } [...] jfyi (just for your information): think about %h3=(%h1,%h2); Best wishes, Maxim mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]