[ Bjarni R. Einarsson / blog: IS EN ]


Perl hash/list/reference quickref

2004-10-16 16:13
Every once in a while people ask me how to do this or that in Perl. The most common questions have to do with lists (arrays) and hashes, how to use references and how to create and use multi-dimensional lists or hashes.

I just finished writing a short Perl example which demonstrates just about all of the syntax involved. It doesn't really explain anything properly, but it is useful because it shows all (well most) of the different syntaxes involved and how they're used. If anyone wants to contribute improvements, that'd be most welcome.

Proper usage of lists and especially hashes can make Perl programs both much more powerful and, in many cases, more legible.


Since I'm writing this I figured I might as well re-link to some older Perl how-to entries I've written:

     Re: Perl hash/list/referen.. (Anonymous)

   
Name:
Subject:

Note: If all you want to do is correct grammar or spelling, please send me e-mail instead of cluttering up the diary. Thank you!

Yes! I will write my own HTML!    

Valid HTML: <P>, <BR>, <A HREF="...">...</A>, <UL>, <OL>, <LI>, <I>, <B>
Blockquote and image tags don't work!

Please leave these blank:

Nýtt í dagbókinni