http://www.perlmonks.org?node_id=998381


in reply to Suggestions for getting a more solid understanding of Perl

Hello imlepid,

It seems to me that “mastering” Perl has 5 stages:

  1. The basics: simple syntax, context, sigils. I’m sure you have this down already.
  2. Perl idioms, including the standard uses of foreach, map, grep, etc.
  3. References and complex data structures.
  4. Regular expressions.
  5. Domain-specific experience with CPAN modules for using databases, etc., etc.

For me, 3 was something of a steep learning curve (but one I eventually got over). But 4 is an ongoing journey of discovery! (For example, see my very recent post Re^2: RegEx + vs. {1,}.)

Now, I would definitely recommend that you acquire the latest edition of the Camel Book, but “reading through” is probably not the way to go. Focused reading, targeting any weak areas in the above list, will likely be far more productive.

And don’t neglect other sources of information: Perl documentation, especially the FAQs, comp.lang.perl.misc, and of course PerlMonks! Also don’t be afraid to challenge yourself. I can’t recommend Higher-Order Perl (free online) by Dominus highly enough in this regard.

Just my 2¢,

Athanasius <°(((><contra mundum

  • Comment on Re: Suggestions for getting a more solid understanding of Perl

Replies are listed 'Best First'.
Re^2: Suggestions for getting a more solid understanding of Perl
by Your Mother (Archbishop) on Oct 11, 2012 at 15:29 UTC

    I like your list but argue there is no idiomatic usage of foreach as idiomatic usage will prefer it be spelt for.

Re^2: Suggestions for getting a more solid understanding of Perl
by aaron_baugher (Curate) on Oct 12, 2012 at 02:12 UTC

    Your list is interesting, because in my own case, your #2 (idioms, map, grep) came at #5, after everything else. I suppose that's because previous experience with C pointers made references easy, and experience with grep and awk did the same for regular expressions (though I agree that there's always more to learn about those). Also, you just can't do a lot of useful work without regexes, complex data structures, and CPAN.

    You can get away without map/grep and other Perlish methods like statement modifiers, though, by using a lot of loops and making your code look like C or some other language. So I tend to think of the idiomatic stuff as the sign that someone's not just capable of programming in Perl, but comfortable with it.

    I suppose everyone's list might be a little different, based on their own previous experience.

    Aaron B.
    Available for small or large Perl jobs; see my home node.