Answer Posted / raghav
Hash/Associative array is the one in which all
the values are stored in terms of keys and values.
i.e., the values are indexed with the help of keys.
You cannot get back the values in a correct order as it
happens in normal array. because in this values are stored
in random positions. The only way to get in a correct order
is to sort that array.
ex: %hash = {"Name","Raghav","Age","26"};
$hash{'Name'} will give "Raghav"
$hash{'Age'} will give "26"
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
Comment on the scope of variables in perl.
How many loop control keywords are there in perl?
How to concatenate strings with perl?
What is the difference between perl list and perl array?
What is the use of -t?
How do I print the entire contents of an array with Perl?
How to create a directory in perl?
Differentiate between arrays and list in perl.
Does Perl have objects? If yes, then does it force you to use objects? If no, then why?
How can you replace the characters from a string and save the number of replacements?
How do I do fill_in_the_blank for each file in a directory?
Why aren't Perl's patterns regular expressions?
What is -> symbol in perl?
What is the use of "stderr()"?
How do I replace every TAB character in a file with a comma?