How to deal with hashes of arrays

In the following pages we'll cover topics regarding the using of hashes of arrays, grouped in two parts, as follows:

Part 1:

  • How to generate a hash of arrays
  • How to use for to traverse and print a hash of arrays
  • How to use foreach to traverse and print a hash of arrays
  • How to use grep to traverse and filter a hash of arrays
  • How to use map to traverse and print a hash of arrays
  • How to use while to traverse and print a hash of arrays
  • How to access or modify the inner arrays elements
  • How to get the hash keys whose corresponding inner arrays match a certain criteria
  • How to get the hash keys whose corresponding inner arrays match a certain criteria
  • How to remove the first element of each inner array

Part 2:

  • How to remove the last element of each inner array
  • How to delete a particular hash entry
  • How to clear a hash of arrays
  • How to insert new elements in front of a particular inner array
  • How to append new elements to a particular inner array
  • How to concatenate two matrices
  • How to copy a hash of arrays – shallow vs deep
  • How to pass a hash of arrays reference to a subroutine
  • How to deal with autovivification in a hash of arrays

Use the menu items from the right side to access these topics.