Top "Perl-data-structures" questions

Discussion of Perl's three built-in data types: scalars, arrays of scalars, and associative arrays of scalars, known as "hashes". At your command-line: perldoc perldata

How do I enter a multi-line comment in Perl?

Possible Duplicate: What are the common workarounds for multi-line comments in Perl? How do I add a multi-line comment to …

perl comments multiline perl-data-structures
Perl array vs list

I have two data structures in Perl: An array: my @array2 = ( "1", "2", "3"); for $elem (@array2) { print $elem."\n"; } Giving me the …

arrays perl perl-data-structures
How do I create a 2D array in Perl?

I am trying to create a 2d array in Perl my code: my @wordsList=(); my @words=(); for ($id=0; $id<=@…

arrays perl perl-data-structures
How can I store multiple values in a Perl hash table?

Up until recently, I've been storing multiple values into different hashes with the same keys as follows: %boss = ( "Allan" => "…

perl hash multiple-value perl-data-structures
How to iterate through Hash (of Hashes) in Perl?

I have Hash where values of keys are other Hashes. Example: {'key' => {'key2' => {'key3' => 'value'}}} …

perl hash perl-data-structures
How can I maintain the order of keys I add to a Perl hash?

How can I maintain the order of actual list after counting its occurrence using a hash in the following program? …

perl data-structures hash perl-data-structures
How does double arrow (=>) operator work in Perl?

I know about the hash use of the => operator, like this $ cat array.pl %ages = ('Martin' => 28, 'Sharon' => 35, …

perl hash operators perl-data-structures
Perl nesting hash of hashes

I'm having some trouble figuring out how to create nested hashes in perl based on the text input. i need …

perl perl-data-structures
What are anonymous hashes in perl?

$hash = { 'Man' => 'Bill', 'Woman' => 'Mary, 'Dog' => 'Ben' }; What exactly do Perl's “anonymous hashes” do?

perl data-structures perl-data-structures hash
How do I reference a Perl hash in an array in a hash?

This is the code snippet I am working with: my %photo_details = ( 'black_cat' => ( ('size' => '1600x1200', …

arrays perl hash reference perl-data-structures