Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: RFC: Perl Learning Plan

by Athanasius (Archbishop)
on Nov 21, 2020 at 07:21 UTC ( [id://11123959]=note: print w/replies, xml ) Need Help??


in reply to RFC: Perl Learning Plan

Hello Leitz,

In looking through this thread, one thing that I don’t seem to have seen mentioned is context, which is a very important part of Perl, and a key way in which Perl differs from most other procedural languages (pace the node immediately preceeding this one). Since your goal is to begin with the basics, your learning plan should include Context in Perl at an early stage, perhaps immediately following Data types and sigils. Here are a couple of references to help you get started:

When you come to study data structures (see perldsc), another concept you will need to learn is autovivification, which is a very useful Perl feature but also a source of perennial consternation to programmers who aren’t expecting it! The classic reference is:

Hope that helps,

Athanasius <°(((><contra mundum Iustus alius egestas vitae, eros Piratica,

Replies are listed 'Best First'.
Re^2: RFC: Perl Learning Plan
by Leitz (Scribe) on Nov 21, 2020 at 12:03 UTC

    Athanasius, thanks! I've dealt with context and autovivication enough to know they are there, but obviously not enough to remember to mention them. I think they would go in with "Data types and sigils" though; it would keep the concepts close together and the learner could more quickly see the richness of Perl's data types. Does that make sense?

      Yes indeed; but I would advise you to keep a sort of mental asterisk by these topics. In my experience, when Perl seems to be doing something strange, more often than not it’s because I’ve overlooked either context or autovivification.

      Which reminds me: you don’t mention debugging strategies, which you will need as you start to experiment with what you’re learning. Be sure to bookmark:

      The sixth strategy, deparsing using B::Deparse, is particularly useful to know.

      Cheers,

      Athanasius <°(((><contra mundum Iustus alius egestas vitae, eros Piratica,

        Added context, autovivication, and debugging. One of the things I do not want to do is write the tutorial. Other's have already done that, and done so much better than I can.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11123959]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2024-04-24 03:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found