

Learning Perl the Hard Way - mbrubeck
http://greenteapress.com/perl/

======
dmv
Interesting -- a GNU Free Documentation alternative book on starting perl for
practisioners. However, the page looks stale. The PDF is (c) 2003, so unless
this is a recent re-release under the GNU Free Documentation License, we may
not see: _the LaTeX source code (with figures and a Makefile) will be
available soon._

~~~
jrockway
Yes, and 2003's "modern" style is what we call "bad" style these days. A lot
has changed in 6 years.

~~~
321abc
Like what?

------
cschep
Any reasons for a newbie to learn Perl instead of Python these days?

~~~
321abc
Here are some reasons for you:

[http://www.indeed.com/jobtrends?q=perl%2C+python%2C+ruby&...](http://www.indeed.com/jobtrends?q=perl%2C+python%2C+ruby&l=)

Python and Ruby aren't nearly as popular as Perl. CPAN, Perl's repository of
libraries, is gigantic, having most everything you can think of already in it;
which makes writing new programs much, much easier.

As much as Ruby and Python fanboys love to beat up on Perl, their favorite
languages have their uglyness and their own faults (which you'll rarely hear
them mention). However, their propaganda really has worked on a lot of people
that really don't know any better. So my impression is that a lot of the newer
stuff is being written for Ruby and Python. So it would probably pay to learn
them for that, if nothing else. But I would definitely think twice before
choosing them instead of Perl.

~~~
ubernostrum
On the topic of propaganda and people who don't know better...

Once upon a time (five years ago or so) I did Perl professionally. At first I
bought into the CPAN hype -- everything's there! Any library you'll ever need
has already been written and is in the CPAN! -- but after actually _using_ it
for a while, I learned that Sturgeon's Law has no exceptions. There were so
many packages which were broken, uninstallable, non-functional or nearly
undocumented that trying to use stuff from CPAN could end up involving more
time than just writing from scratch.

When, one day, I encountered documentation for one project which listed all
its dependencies, and then gave a long list of things it needed which were in
CPAN but in such broken states that CPAN couldn't actually be used to install
them (and an even longer list of instructions for how to manually install and
work through the bugs), I started looking for something else.

~~~
321abc
So you're saying other languages have somehow magically managed to keep their
third party packages and libraries from ever breaking? Or that they don't have
dependencies?

Look, when you've got a large enough library of third-party contributions,
some portion of them will be broken. And the more libraries people use to
build their own libraries, the more dependencies there'll be.

Let me know when some other languages manage to solve these problems, or when
the upstart languages actually get enough third party libraries for them to
have to start facing this problem themselves.

~~~
ubernostrum
I'm saying that an awful lot of Perl advocacy is predicated on CPAN, and that
-- since Sturgeon's Law doesn't have an exception for the CPAN -- this is
basically the same sort of overhyped propaganda the parent comment was
lamenting from other languages.

That in no way implies any of the statements you're attempting to shove into
my mouth, however, so perhaps you should step back a bit and reconsider what
you're saying?

~~~
berntb
The disadvantage with CPAN is that you need to know what you're doing (or
check Perladvent and ask on Perlmonks.org).

How many DateTime modules are there? Which one is _really_ used by everyone
the last few years -- and when should you use the previous one?

CPAN is, afaik, better than anything else out there.

------
rjurney
There's an easy way? :)

~~~
321abc
Randal Schwartz's "Learning Perl" was one of the easiest and most entertaining
introductions to any language I've ever read.

~~~
rjurney
Yes, that book is great. Just a joke about Perl's relative syntactic
obscurity. I love me some Perl because of the elegance and power the operators
provide me, but its murder on a noob, especially if its not great code.

~~~
321abc
The same could be said of any language. Perl's just gotten beat up on by fans
of certain other upstart languages that want to steal some of Perl's glory.

In five or ten years there'll be some other language fad, and those languages
will get their turn at being the whipping boy.

~~~
ubernostrum
"Perl's just gotten beat up on by fans of certain other upstart languages that
want to steal some of Perl's glory."

Or... maybe there's a kernel of truth in it? Yes, all languages have weird
gotchas and corner cases. But there are times when Perl seems to go out of its
way to have as many as it can manage, which turns the process of learning Perl
into a long campaign of trial-and-error experiments and rote memorization.

It's sort of like trying to find a consistent pattern in the naming of PHP's
built-in functions, except it applies to the entire language.

~~~
berntb
Perl is inspired a bit by natural languages. It is certainly harder to learn
than some other languages.

The Perl Best Practices book is needed for all teams (it saves on long
discussions; "this page list what we do different to PBP").

