On Aug 8, 11:26 am, [EMAIL PROTECTED] (Oryann9) wrote:
> Is this an array of hashes desingnated by { }?
>
> my %month;
> @month{ qw/Jan Feb Mar Apr May Jun Jul Aug Sep Oct
> Nov Dec/ } = 0..11;

No.  That is a hash-slice.  Just as you identify one value of a hash
by changing the % to a $ and putting the value's key inside braces:
$hash{'key'} = $value;
you can identify a list of values of the hash by changing the % to a @
and putting all the values' keys inside braces:
@hash{'key1', 'key2', 'key3'} = ($value1, $value2, $value3);

Read more on this syntax in: perldoc perldata

Paul Lalli


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to