Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

RFC: Perl Learning Plan

by Leitz (Novice)
on Nov 18, 2020 at 23:37 UTC ( #11123800=perlmeditation: print w/replies, xml ) Need Help??

Learning difficult topics like programming languages, human languages, or the thought processes of the opposite gender can be challenging. Over time, too much challenge can be discouraging and can end the effort before success is achieved.

In my own learning efforts I have found great success in mapping out the core topics for my next level. Doing so lets me focus on what I need right now and avoid stress about not learning things beyond my current level goal. In Perl, for example, I should really know the syntax and uses of hash references before I dig into object oriented web frameworks. While the idea seems simple, and it is, it does not seem common. For me it has helped in everything from programming languages to things like human languages, shooting sports, writing fiction, and searching for new jobs. Pretty much every aspect of my life has been helped by making a good plan for the next step and ignoring everything else. Except for the "opposite gender" bit, I'm still working on that one...

Here's my learning plan for becoming a well rounded Perl Apprentice. The goal is to have the basics down solidly so that I can begin my journeymanship. Until these topics are firmly embedded in my head and skills, I do not need to be trying to do Expert Perl stuff.

Data types and sigils

  • scalar, list, aray, hash, subrouting, references, objects
  • Variable assignment and Scope
  • Context
  • Autovivication

Control Structures

  • if, for, foreach, until, while, ...

Pattern Matching

  • Just the basics

Files

  • reading and writing
  • tests and operations
  • Directories

Modules

  • Loading and using Standard Library modules
  • Using CPAN

POD

  • Documenting code

Testing

  • Writing and using basic tests
  • Debugging

CLI

  • Input and output

Process Management

Replies are listed 'Best First'.
Re: RFC: Perl Learning Plan
by eyepopslikeamosquito (Bishop) on Nov 19, 2020 at 00:39 UTC

      Hey, thanks for this! Life actually slowed down enough, just for a little bit, and I made time to read Norvig's "Teach Yourself Programming in Ten Years". His statement about staying interested enough to keep it fun is where I'm struggling most right now.

      Perl is a great language, but it's difficult for me to find ways to enjoy it while overcoming the cognitive load of parsing sigils and braces and arrows (oh my!). I will press on because my team uses Perl and I will do the best job that I can. I use personal projects to learn more and keep it interesting, but it's work. Part of my learning plan's purpose is to help me feel like I'm making progress when it feels like I'm going nowhere.

      Josh Kaufman wrote a book called "The First Twenty Hours". Really, you can learn the basics of a lot of things in a well crafted chunk of learning time and twenty hours is a great measure of 'I learned the very basics'. There's an entirely different measure when you start to dream and the problems are being solved in a language you love. When you can't wait to get up in the morning and work with your language. When you want to contribute back to what you love.

      I'm not there with Perl. It's a great language, but it's still more like talking to my ex than spending time with the girl that smiles when I show up.

Re: RFC: Perl Learning Plan
by Leudwinus (Sexton) on Nov 19, 2020 at 01:49 UTC

    I am still a novice programmer myself (I do this as a hobby) and have dabbled in a number of different languages, Perl being my latest infatuation. Part of me feels that I should have followed your prescription to assiduously understand the foundation of each language I’ve flirted with to really master it.

    But alas, that doesn’t work for me as I don’t have the patience.

    For me, to learn and appreciate a language, I have to use it to solve a problem, even if its a contrived one such as the Project Euler challenges, the bioinformatics problems on Rosalind, or, hopefully later this December, the next installment of Advent of Code. The same approach applies whether the language I’m learning is Perl or Brazilian Portuguese. That’s the only way I can retain my motivation to keep going.

    Having said that, everyone learns differently so I’d be very interested in hearing how your journey progresses so please keep us updated. Good luck!

      Leudwinus, I agree with you; "learning by doing" is the only way to become a programmer. I wrote a blog post on "The Best Programming Language". It was about finding the best language for an individual; we have different problem sets to solve and different brains to solve them with. "The Best Language" for each of us is the one that inspires us to code more, so that we learn more.

      There are really two questions that have to be dealt with when we approach a new language. You hit on the first one; "How do I learn?" I tend to read a chapter of a book, and they write very small toy programs. How do I build a hash? How do I change a value in it? Later on I look at how to merge two hashes or call them by reference. When I get going, I'll start a personal project to accomplish something that is important to me. That pushes me to learn more and to keep programming. The code will be pretty ugly and need a lot of work, but it is a learning tool.

      My list helps with the second question, "What do I learn?" I often try to take on things I just cannot comprehend. Breaking down the basics into a list lets me focus on learning those basics, one at a time. I can then go back to the big problem better prepared.

Re: RFC: Perl Learning Plan
by Discipulus (Abbot) on Nov 19, 2020 at 11:08 UTC
    Hello Leitz and welcome to the monastery and to the wonderful world of Perl!

    you already have collected good suggestions and your plan seems sane, just some other thoughts from my part.

    Learning is not a linear process: take other resources as side companion in your journey and they might stimulate even more your will to learn.

    I liked a lot the Perl Cookbook even if it is very old, because its recipe approach: you will get a lot of inspiration glancing it while following your own learning plan.

    Also get your free copy of Modern Perl Book and give it some sparse read to confirm your skill. It is not intended for beginners but show you a fresh and modern look to the language with most up to date idioms (you can learn from old perl examples because perl is highly backward compatible, but you must write modern form of them :)

    You can be also interested in some link of my small bibliotheca

    L*

    There are no rules, there are no thumbs..
    Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.
Re: RFC: Perl Learning Plan
by LanX (Cardinal) on Nov 19, 2020 at 00:20 UTC
Re: RFC: Perl Learning Plan
by Fletch (Chancellor) on Nov 19, 2020 at 15:44 UTC

    More of a longer term recommendation, but once you've got the fundamentals Higher Order Perl is a good mind expander (and then not perl but in the same functional vein Learn You A Haskell For Great Good).

    The cake is a lie.
    The cake is a lie.
    The cake is a lie.

Re: RFC: Perl Learning Plan
by Athanasius (Bishop) on Nov 21, 2020 at 07:21 UTC

    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,

      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,

Re: RFC: Perl Learning Plan
by tweetiepooh (Hermit) on Dec 02, 2020 at 15:29 UTC

    One thing that I really like in Perl is getting something to work very quickly and very easily. Think how easy "Hello world!" is in Perl compared to other language that may need to load methods/modules etc first. Then how quickly you can modify that to do different things.

    When I learnt Welsh at university the class I did (evenings) used wplan which is based on the techniques that Israel uses to teach new immigrants Hebrew - the main focus is to get to use the language quickly so you can practice it in real situations. I think the same is true in programming - get to actually do something with the language, have a goal, and then get all the syntax and stuff right later. Get to do something "fun" as early as possible

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlmeditation [id://11123800]
Approved by LanX
Front-paged by LanX
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2020-12-03 08:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How often do you use taint mode?





    Results (53 votes). Check out past polls.

    Notices?