To assign an individual key/value pair try:
You will notice that the % sigil has change to a $. Remember that $ looks like the s in scalar. It means just a single piece of data. When you get a little more advanced, you can check out hash slices.$hash{'key1'} = 4; $hash{'key2'} = 5;
There are plenty of resources for learning Perl:
Cheers and keep trying
In reply to Re: adding to a hash
by Limbic~Region
in thread adding to a hash
by powerhouse
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |