Chromatic has written up a good summary of the current
state of Perl 6 development for the
O'Reilly Perl.com site. He talks at length about the advantages of Perl 6 and addresses the question everyone is of course asking. When's it going to be ready? The answers of course is, as always, it'll be ready when it's ready...
I actually didn't spot this article till it
hit Slashdot, and looking through the comments it generated I was actually fairly surprised by the amount of anti-Perl feeling out there. After all, everyone I know loves the language, and for the record a list-of-lists isn't hard...
my @list = ( [1,2], [3,4], [5,6], [7,8] );
I don't really think the syntax is so hard, so what's the
problem here guys? In fact if you understand the underlying data model you're dealing with, the syntax is obvious. You wouldn't try to code in a language where you don't understand how the data is stored, right?
With respect (and I mean that), to a relative newbie, Perl is daunting. Its syntax, its users, its advocates and its documentation - especially its documentation - are daunting. Python offers a much shallower learning curve - at least it seems that way.
ReplyDeleteHowever, the more I learn, the more I understand Perl and the more I like it (er.. the less I dislike it is probably more accurate!).
Perhaps the 'list of lists' example is not a good one - it does indeed seem trivial in both languages, but to imply that one should not code without fully understanding the underlying data model is unfair.
Whilst it is undoubtedly important to learn about the mechanics of a language, it is equally important to be able to sit down and produce working code - both as a legitimate learning exercise and as a valuable incentive to delve deeper into the workings of the language. Perhaps it is this kind of - dare I say it - elitist sentiment that scares many people away from perl.
Funnily enough, today I started teaching a three day Perl course (rather than thinking about theoretical physics which is my day job) and for that I have looked around a bit how the alternatives are doing. I do not program for a living so writing Perl programs is mainly for fun (and to get the odd job done) so my view is probably biased.
ReplyDeleteWhen I learned Perl seven or eight years ago (that was my motivation to start programming again after I got bored writing code in other languages, mainly C as Perl is fun!) main competitors around were Java and PHP. For everybody only slightly serious about Perl it was clear where its advantages were.
However today, I find all kinds of testimonials of how great Python and Ruby (on Rails) are. I am not convinced but maybe these people have a better point than the supporters of PHP and Java for tasks I would use Perl for?
Anyway, I think that this lists of lists issue is the most confusing part of perl. Not the literal that Al listed above, but a bit more complicated data structures with require several levels of dereferencing references do confuse me and often I have to use a trial and error approach to get the {}'s that I need to disambiguate right.