P
pmak00
How can I abbreviate the following code:
$foo->{apple} = $bar->{apple};
$foo->{orange} = $bar->{orange};
$foo->{pear} => $bar->{pear};
$foo->{grapefruit} = $bar->{grapefruit};
I'd like to be able to type something like:
hashCopy($foo, $bar, qw(apple orange pear grapefruit);
Is there already a built-in function like hashCopy()? Or do I have to
make my own?
$foo->{apple} = $bar->{apple};
$foo->{orange} = $bar->{orange};
$foo->{pear} => $bar->{pear};
$foo->{grapefruit} = $bar->{grapefruit};
I'd like to be able to type something like:
hashCopy($foo, $bar, qw(apple orange pear grapefruit);
Is there already a built-in function like hashCopy()? Or do I have to
make my own?