Perl is a mess and that's good because the problem space is also a mess.
Larry Wall
As you may have noticed all around this site, I'm just another perl user for multiple purposes. Perl ain't no real acronym, even though some have found it a meaning, and you write "Perl" when you talk about the language, "perl" when you talk about an implementation of Perl. Here are a bunch of things I understand about Perl's philosophy.
Perl is a free programing language, Open Sourced by it's creator, Larry Wall. It is available under many platforms in the shape of distributions. It is shipped with all Linux distributions and most MacOS X releases. It can be easily doanloaded and installed under Windows thanks to ActiveState.
So Perl is a language but how is it used ? What can be done with it ? Does it qualify as a programing language ? I would answer yes but many people still view perl as a simple scripting language linked to small tasks. So much can be done with perl, from CGI scripts to complex GUIs, from one liners to complete operating systems. We'll settle for the verb to code because it sounds more neutral and it carries the fact the you can really translate in perl one idea you have in mind. Advanced perl experts self-title themselves as hackers in it's good acceptance.
I'd dream of being called a perl hacker but I'm just a perl tourist.
So many people have historically associated perl with the CGI protocol that they seem completely tied together. The fact is that CGI is just a gateway that can be processed in any kind of language, perl only being the most popular choice.
Today language of choice for dynamic content seems to have moved away from perl through CGI solutions to PHP. I ain't no PHP expert but when I read books about it or read scripts in this language, if find it so narrow minded that I always come back to perl. I find PHP code has such poor semantics, is so task-oriented, protocol tied, ... it looks to me as coding for the dummies. The more I get to know PHP, the more I wonder if there can be such a person as a PHP magician or at least PHP hacker.
Perl may have turned old school but the point remains that it's a full blown programing language that can also be used for scripting. It's such a rich language that code reflects one's style and personality.
When so many programing language have some sort of coding orthodoxy, it is commonly admited in perl to take have freedom oriented acception of the syntax and the algorithmics. It's not total freedom because it has to be understandable by computers but the intent is to design the language around the shape of the human psyche. There's a lot of freedom in perl coding.
The pragmatic approach to perl coding is that you turn into the direction of orthodoxy when you have a problem, in a dead end situation, when perl doesn't do what you expect it to. You are free to code the way you want to, but when it comes to your limits, the first place to ask for help is inside perl. Asking perl to help you is a prequisit before posting to a newsgroup or mailing list.
The first step in this direction is to enable warnings (perl -w or use warnings). It'll let perl give to tips and hints about possible caveats in your code. It'll accept your code as it is but will output advices like mentioning possible typographic mistakes. To let perl help you, it asks you for more formalism so that it gets a better idea of what you're trying to achieve. The strict mode (use strict) is more constraigning as it requires explicit declarations and will refuse to work if you don't respect it's formalism but this self-discipline leads to powerful debugging.
Don't ask for help to humans through a mailing list or newsgroup before asking for perl's warning and using the strict mode. It's not the cult of a certain form of orthodoxy but a productivity orientated approach to self-management principles. The idea is not to force people into a preconceived mold, a certain way of thinking, but find common standards to human readability.
The one thing I like about perl is that the language is so simple. Quite easily can you get started and achieve simple tasks. When it comes to larger operations, you never have to recreate the wheel but get the help of people who have been facing the same problem. There's this mythical place called the CPAN, Comprehensive Perl Archive Network. There can you find distributions to suit your needs, documentation, examples, etc. as may be found in other languages, but also a repository of hundreds of modules. Modules are bits of code that let you expand the possibilies of perl. There are so many modules that there's almost always at least one to do what you want.
There's amongst the perl users a true sense of community that leads people to share their knowledge of a programing problem and give back to the world the solution they have found. It's all about recycling wisdom. The CPAN lists 7345 modules today but new ones emerge everyday. This leads to a modular and flexible approach in cognitive space. It's all free information centralized in an harmonious way.
Perl creators have tried to make it as simple as they could to let one expand the possibilities of his copy of perl, but we must admit that it's not always as simple as it should, mainly because modules depend upon other modules being present and the fact that some modules are not written in perl. Perl itself is not written in perl. With ActivePerl under Windows, modules are really easy to install, it's almost automatic, but under other platforms it can be difficult.
Making all these modules available in a centralized place is only part of the knowledge diffusion about perl. There's this global incentive to share your code, even if it's not a module or if you're not sufficently happy with the code to make it rest on the CPAN. I'm a poor perl coder but I try to show what I've done in case it might help someone else. This is a common behaviour inside the perl community.
The other aspect of this information socialism, advanced knowledge distributed to the masses, is that perl is interpreted and not compiled. When you work for someone else, in the end, you get payed for the code, not the program. This is really different from compiled languages where you can give the executable program and keep the code for you. One may say that Perl is socialist by design, others that it's distributed by technical necessity, but in the end, what matters is that the works gets done and the output can be improved by anyone else.
This socialism has also consequences in religion about perl. Pure perl adopters try to make their code as system-agnostic as they can. Because perl has been ported to so many operating systems, the code you display should show most of it's portability. There has to be flexibility even if you can, by ease of writing or use, have a bit of code that is system tied.
We write knowledge socialism, not knowledge communism, because there has to be ways to make money out of Perl. The language has it's ethics and it's artistic licence. There's more than one way to do it and more than one way to use it. One may choose Object-Orientated programming when one may stick to basic interfaces. There is freedom but the aim is the same, get the task done.
We will encourage you to develop the three great virtues of a programmer: laziness, impatience, and hubris.
Larry Wall, Programming Perl, 1st Edition
There is some extent of magic when you write code in perl. The more you know the language, the more litteracy and boldness you can introduce. Perl code can be pretty straightfoward to explain to someone who doesn't understand it but can turn into a nightmare when obfuscated, or an art as perl golfers (people who try to achieve a task in the minimalest zen code). The regular expression are the most tricky part to explain as it doesn't relate easily to english language but they provide such a landscape of dense pure genius that it's worth digging.
There are so many ways to write an action that coders can really express a style that reflects their personality or mind. Code can be fun, strict, loose, talkative, addictive, intense, ...
The learning curve is pretty simple and thanks to O'Reilly we have excellent books if you're reluctant to onscreen docs.
With just a few words, I can automate tasks that are so complex that I always feel a sense of magic. The possibilities seem endless and the experience is whimsical. I ain't no programmer (I've only been studying law and information sciences) but over all the languages I've had to use, perl really stands out. I code for leisure but knowing that one can earn a living out of it sounds too good to be true.
I still have so much more to learn about it that i can rest apeace. I just wanted to use this space to propagate my kudos to the world that has provided such a language. I am thankful and I wanted to share that with the hope that some of the readers of the page will turn themselves into perl hackers and make this world a better place, or at least, a smartest soundest one.
A camel is a horse designed by a committee.
Larry Wall