in reply to help w/hash arrays

Others have given some good explainations, no need to repeat them. But here are two tips: Data::Dumper is your friend, and you can use print statements to help tease apart these statements.

  1. Data:Dumper is wonderful for figuring out data structures. Just add a
    use Data::Dumper;
    at the start of your code, and then add a line like:
    print Dumper(\%students);
    You'll get a nice printout of the data structure and its contents. By the way, the backslash returns a reference to the variable it precedes.
  2. You can also try printing things to find out what they are. If you print a reference, you'll get something like SCALAR(0xda28) with a datatype and an address/uid.


TGI says moo