Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

(Blue) Re: What is it about perl that makes perl so cool?

by Blue (Hermit)
on Dec 01, 2000 at 20:13 UTC ( [id://44386]=note: print w/replies, xml ) Need Help??


in reply to What is it about perl that makes perl so cool?

One of the things I like about Perl is that it's easy to get into, but you won't outgrow it.

Reading this list, seeing people talk about CPAN, I was tempted to talk about the community of Perl and how gosh darn cool it was. but then I realized that if I was stuck on a desert isle with no connection to the world, no CPAN, no PerlMonks, no web pages, Perl would STILL be a cool language.

Back to my original point. Traditionally, 'powerful' languages had a steep learning curve even to do the basics and were rather unforgiving. I think we can all agree that this doesn't fit Perl. On the other hand, traditionally easy to pickup and program languages lacked power and growth. Look at that LOGO turtle go! I think we can all agree that this also does not describe Perl.

I picked up Perl, and immediately felt welcomed into it. It made it fun to program. Yet several years into it I can *still* learn a new thing a day. Not just 'a new thing', but 'a new thing A DAY'. Think about the limitless possibilities of Perl.

To put it another way, the leading edge and the training edge of 'the Perl experience' enclose such a large area. It's a joy to get into (the close leading edge), yet you do not 'outgrow' it. Perl is easy to learn not because it's underpowered or dumbed down, but because it's smart enough to do 'the right thing' as well as having a forgiving syntax, more then one way to do something, copious error checking and messages, etc. And the entire idea of modules (ok, CPAN does work it's way back in) means that when you take Perl far, even there are building blocks that keep coding a joy of creation instead of a chore of worrying the details to death.

That's the number one reason I prefer Perl.

=Blue
...you might be eaten by a grue...

  • Comment on (Blue) Re: What is it about perl that makes perl so cool?

Replies are listed 'Best First'.
(jcwren) Re: What is it about perl that makes perl so cool?
by jcwren (Prior) on Dec 01, 2000 at 20:57 UTC
    Reading this list, seeing people talk about CPAN, I was tempted to talk about the community of Perl and how gosh darn cool it was. but then I realized that if I was stuck on a desert isle with no connection to the world, no CPAN, no PerlMonks, no web pages, Perl would STILL be a cool language.

    I'm not sure I agree with this. Well, depending on what resources you have on your island. Do you have the source? Do you have perldoc? Let's say you don't have the source for Perl, nor perldoc (obviously not a real *nix system running here...). Can you remember all the keywords and constructs? With C, you have 27 or 32 key words. With C++ it's a few more. With average (modern) BASICs, it's like 100+. Java I can't remember.

    Now, with C, you could feasibily remember your 27 keywords. And anything you need can be built on those 27 keywords (by the way, Forth is probably the best at this paradigm!).

    While you could definitely still write useful software in Perl with the basic knowledge, you couldn't fully exploit it. Now, if you happen to have the ORA CD Bookshelf, then it's a whole different story.

    And perhaps this spawns a thread in itself. How often do you refer to the documention? I use certain features of the langauge infrequently, and when I don't use them, I either have to look them up, or hack at it to get it right. I sling LoLs of LoLs about with impunity, but am pretty weak with regexs. I have virtually no experience with autoloaders, but am comfortable with writing packages. I don't do sophisticated OO, but dont' always take the shorted path to getting somewhere. My excuse is I don't use Perl 100% of the time (I do a lot of embedded C and assembly).

    What would you (the reader, not just Blue) consider your strengths and weaknesses in Perl? Will you attempt to improve the areas you're weak in, or wait until you need to do something with that feature?

    --Chris

    e-mail jcwren

      I have to disagree, there are so many ways of skinning a cat with perl, it is not always a disaster to forget the syantax of a keyword. How many map calls could be replaced with for and push? I imagine all of them.

      However, you are quite right, it would be impossible to "fully exploit" the language. But do any of us do that now, with all the docs to hand?

      --

      Brother Marvell

      In answer to you question on the use of documentation ...

      I tend to grab for the Perl 5 Pocket Reference quite often. Sometimes I find myslef searching in perlfunc. Perl in a Nutshell get it's uses as does the Perl Cookbook. Even less ... Advanced Perl Programming helps me with LoL type problems. I don't find I need those advanced techniques all that often.

      --

      Brother Marvell

        Advanced techniques?

        I use them all of the time, and the trick is that they are not very hard (at least not in Perl). For instance a hash of hashes? That is just a directory structure:

        # Name it absolutely $foo{some}{path}{to}{the}{thing}{I}{want} = "something"; # Or relatively: my $h_ref = $foo{some}{path}; foreach my $thing (keys %$h_ref) { print "Found key '$thing' with value $h_ref->{$thing}\n"; }
        It is just an odd delimiter. *shrug*

        For the next trick look at map and grep and the general list-oriented nature of Perl and see it as a Unix pipeline written (unfortunately) right to left instead of left to right. Now stare at the Schwartzian sort and see why it is so natural.

        In no time these "advanced" techniques will feel like part and parcel of how things work... :-)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (4)
As of 2024-04-26 00:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found