my %data = ( 'keyA' => 'valueA', keyB => 'valueB', # fancy => allows bareword 'keyC' , 'valueC', # equivalent );
See perlop and perldata. And be carefull with terminology: better say only 'array' (the @ variable), 'hash' (the % variable) and 'list' (no variable), because a list is something quite different from an array and a hash is not too much an array.
--In reply to Re: Initilize a hash array
by fruiture
in thread Initialize a hash array
by nedals
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |