|
Last updated: 06/30/2009
Sometimes it's nice to have a hash element point to a list of items, rather than just a value. To do this, add elements to the list like this:
push(@{$hash{$key}},$list_element);
You can access the list like this:
@{$hash{$key}}[0]
or looping through the list as normal.
blog comments powered by
|