|
|
| Perl Monk, Perl Meditation | |
| PerlMonks |
Re: Answer: How do I push new data into an existing hash?by arturo (Vicar) |
| on Apr 19, 2001 at 15:23 UTC ( [id://73846]=note: print w/replies, xml ) | Need Help?? |
This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.
Try $hash{$key} .= $val; if $hash{$key} is a (string) scalar, or push @{$hash{$key}}, $val if $hash{$key} is an array reference. See perldoc perlref and perldoc perlreftut for more on how to play with references.
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||