Programming in Perl is difficult, because it is not intuitive. It is good, though. Sometimes I experience a certain relief when I find an elegant solution to an old dilema. And more often than before I put comments like
# THANK YOU, LORD!
or
# Glory to God in the Highest!
inside my code. Why? Because I'm not a perl programmer, I am a perl user, I suppose. Although I managed to write quite an extensive application in Perl, I feel like my learning of this language will never end. Unfortunately.
Don't you wish you would be able to say "I speak Perl fluently". How many of you out there can say that honestly? Does Perl have to be difficult?
How about one of my recent eurica's:
sub copy_button { my ($item, $item_id, $parent_id) = @_; my $kids = { pilot => 'survey', survey => 'section', section => 'question', question => 'option' }; my $ref = $dbh->selectall_arrayref(" SELECT ID, NAME FROM $$kids{$item}s WHERE $item\_id = $item_id "); return submit({ name => 'copy_'.$item.'_'.$parent_id, value => 'Copy' }) . popup_menu({ name => 'source', value => [ map ($$_[0], @$ref ) ], label => { map {$$_[0], $$_[1]} @$ref } # Glory to God in the Highest! }); }
I wish it would be simpler. Should I try Ruby?..
Natural language
jmm on 2003-05-07T20:56:03
Like natural languages, you can talk baby talk in Perl and communicate usefully. And, like with natural languages, there are always new levels of mastery possible. Most of us are not yet capable of writing the equivalent of Romeo and Juliet in Perl.Re:Natural language
dreadpiratepeter on 2003-05-08T03:00:54
Maybe, but Damian's SelfGOL has to be James Joyce's Ulysses.
Re:Simpler != Better
avik on 2003-05-12T02:54:05
I still think that simpler is better. Specially, if it requires to be passed around to another (unsuspecting) individual, other than yourself. So called "Monastery" is a good idea, can't argue with that, but, excuse me, Perl is not a religion, it does not require a monastery, monks or following... It's a programming language... Right?...Re:Simpler != Better
chaoticset on 2003-07-31T12:43:51
Yes and no. Some people like it so much that they become, more or less, "disciples of the faith".I think it's more about what it is to you. If you want it to be a regular ol' programming language, it's certainly that. But there is a sense of community that follows the language around the battered* landscape of the Net, and the resource that the community can be is invaluable compared to the language.
I know it's frustrating at times. Just yesterday night I banged my head against regex after regex, and they're easy regex, they're not really that complex, and I should know better by now.
It's a long, winding path. So is every other language. One of the differences with Perl that I like so much is that more advanced features don't typically require lots of extra code -- usually, you just slap a module into the appropriate place.
So, yes, it is -- but to some people, it's more than that. If it's not to you, nobody will fault you for it. I'd still recommend you check out CPAN, though.
:) Re:Simpler != Better
jdavidb on 2003-07-31T17:14:06
Perl is a society, and we use a lot of analogies for that society.
If it makes you feel better, pretend the monks are Jedi adepts. Stronger in the force I feel you growing, young padawan!
:)
So you're saying you're a novice. That's OK. As Larry said, "You can write baby Perl and we won't laugh." But you may want to learn the seven stages of a Perl programmer and see how soon you will become a Perl Adept. (I'm still working on it myself.)
Re:Keep growing, er, going
avik on 2003-05-12T02:56:21
Ay-mart, I want not to become a Perl Adept, just a Perl programmer... Okay, let me look at your link:) Thanks!
Re:You'll never stop learning Perl...
avik on 2003-11-21T15:09:53
This is deep. Thanks for your comment back in July. I'm getting better in learning Perl idioms and ways to do job better. Still use VBA for quick analytical projects, though, it's just so much easier to put something "quick and dirty" together than it would be in Perl. But Perl really saves a lot of my time on some things where VBA just gives up.