http://qs321.pair.com?node_id=550296

This may or may not be off-topic. It does involve Perl, at least peripherally, though.

Not long ago, I found myself telling someone "People who live in houses made of Windows shouldn't throw stones." The follow-on to that, of course, was my statement that "I'm glad Linux was built from reinforced concrete."

In relating this to another audience, being inordinately impressed with my own cleverness, I got this response from Sterling "Chip" Camden: "So you only have to avoid throwing jackhammers."

Being the contemplative sort that I am, I found myself considering that statement as it relates to concrete (pun intended) reality. I noted that Linux seems to come with the software equivalent of tools like jackhammers (and backhoes and water saws and every other frighteningly powerful industrial tool out there), while Windows mostly seems to come with pebbles. As I considered it in more depth, I realized that this correlation of included tools' destructive ability to the power and flexibility of the system seems to bear out across other OSes as well, and even into other realms.

Two other realms in particular to which I've applied the concept conceptually are the sociopolitical and programming languages. Most of you will have heard Perl called the "Swiss Army Chainsaw" of programming languages, of course: if you're not careful, you could easily saw off your own leg, to say nothing of the fact that it's ugly and noisy and belches noxious fumes while you're using it, but that all provides a great deal of versatility and power that is rare in other languages. What it really boils down to, as far as I can tell, is this: By providing the tools, you empower those who know how to use them to do great things. Those who are both incompetent to use such tools effectively and too irresponsible to avoid dangerous tools when they should do so become victims of their own willful ignorance. It requires a little bit of willingness to take responsibility for one's own actions to avoid being a menace, but when others who have that sense of responsibility have the same tools they provide sort of an insulating layer against the behavior of the irresponsible few, and the system as a whole is strengthened.

There was a lot more thought going into this than the above, but that's kind of a summary of some of the important stuff. Ultimately, I distilled the whole thought process into what I call

Perrin's Principle of Inclusion:

The strength of any system is directly proportional to the
power of the tools it provides for the general public.

I guess it's sort of an answer to (for instance) the Perl-dismissers amongst the Java crowd who complain about how "dangerous" Perl can be. The answer is that the language is merely powerful and flexible; it's the programmer who can be dangerous. Allowing the programmer that power and flexibility is a net win, however, because of what I (hubristically) called Perrin's Principle of Inclusion.

print substr("Just another Perl hacker", 0, -2);
- apotheon
CopyWrite Chad Perrin

Replies are listed 'Best First'.
Re: Principle of Inclusion
by sub_chick (Hermit) on May 18, 2006 at 18:06 UTC
    I enjoyed reading your "Principle of Inclusion" and its explanation. Just a couple of days ago, I had a talk with a C Programmer who displayed his dislike of Perl. When I asked 'Why?', he replied, "Because it's a programming language made to be very loose and flexible and therefore very vulnerable."
    I then explained the TMTOWTDI viewpoint and itsflexiblity in hopes that was the reason why he called Perl "loose". He eventually saw the light and realized that its based solely on the programmer's skills and experience. Lastly, he decided to give Perl another try and actually READ books and manuals this time around.

    Es gibt mehr im Leben als Bücher, weißt du. Aber nicht viel mehr. - (Die Smiths)"

      C Programmer .. it's a programming language made to be very loose and flexible and therefore very vulnerable.

      pot meet kettle ... kettle, pot

      -derby

      Has he gotten around to reading said books yet? Is there progress? Enquiring minds want to know — or, at least, I do.

      print substr("Just another Perl hacker", 0, -2);
      - apotheon
      CopyWrite Chad Perrin

Re: Principle of Inclusion
by BrowserUk (Patriarch) on May 18, 2006 at 20:55 UTC
    Actually . . . there's statistical evidence to suggest that more lax firearms laws lead to reduced violent crime rates

    In 2001, the USA suffered 29,573 deaths by gunshot from a total population of 285,317,572.

    In 2001, the UK suffered 167 deaths by gunshot from a total population of 58,789,194.

    In 2000, 75,685 people were treated for non-fatal gunshot injuries in the USA.

    In 2000, 102 people were treated for non-fatal gonshot injuries in the UK (England and Wales).

    You might *feel* you are safer due to your right to bear arms, but you aren't.

    And your feeling about OSs is equally coloured by what you want to believe, rather than reality.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
      Do many people care what method/instrument was used to murder them? Wouldn't a better statistic be the overall murder rate?
      • United States  --     0.042802  per 1,000 people
      • United Kingdom --     0.0140633 per 1,000 people
      A reply falls below the community's threshold of quality. You may see it by logging in.
      In 2001, the USA suffered 29,573 deaths by gunshot
      Can you please provide the source for your data? The FBI's Uniform Crime Reporting Program lists 8890 murders by firearms. And it looks like there were 14758 firearm suicides in 2001.

      Thanks.

        Gun deaths in USA 2001


        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
        "Science is about questioning the status quo. Questioning authority".
        In the absence of evidence, opinion is indistinguishable from prejudice.
        Personally, I'm not worried about criminals with guns, I'm worried about idiots with guns.

        From your cdc link: "and an estimated 29,721,821 persons with nonfatal injuries...27,551,362 (92.7%) were unintentional"

    A reply falls below the community's threshold of quality. You may see it by logging in.
Re: Principle of Inclusion
by TedYoung (Deacon) on May 18, 2006 at 17:42 UTC

    Added Note: Sorry, I didn't want to start a debate on gun control and end way OT. I was only making a joke about using a gun for day-to-day things like opening a can of soda. I was just exaggerating and being silly, not expressing any particular oppinion or datum.

    Good thoughts! This reminds me of guns. Guns don't kill people, people do. But, there are many people who use guns regularly (i.e. turning the TV on and off without getting up or opening a can of soda) without injuring anyone. Getting rid of the guns might help with the crime rate, but it will make those day-to-day tasks harder.

    Seriously though, I remember the day when software came with one to two inch thick manuals. There was an expectation that the user would read it before using the software. Nowadays, people think they should be able to sit down with something they have never used before and be instantly productive. Perl has a really thick manual. Those that choose not to read it, do so at their own risk. Those of us that do, reap the benefits.

    Update: fixed some speeling erors.

    Ted Young

    ($$<<$$=>$$<=>$$<=$$>>$$) always returns 1. :-)

      Actually . . . there's statistical evidence to suggest that more lax firearms laws lead to reduced violent crime rates. Check crime rate statistics for Kennesaw, GA when it instituted a local ordinance requiring that every head of household maintain a firearm back in the early '80s, and for the state of Florida when it instituted its "shall issue" policy for concealed carry permits.

      Violent offenders tend to be more afraid of private citizens with guns than the police. "Getting rid of guns" doesn't seem to help with the crime rate at all.

      As for the rest of your post, I like your observations, and tend to agree. Thanks for the kudos commentary.

      edit: Please ignore my bizarre term substitution. I don't know why my fingers decided to type "kudos".

      print substr("Just another Perl hacker", 0, -2);
      - apotheon
      CopyWrite Chad Perrin

Re: Principle of Inclusion
by Anonymous Monk on May 18, 2006 at 17:57 UTC
    Most of you will have heard Perl called the "Swiss Army Chainsaw" of programming languages, of course: if you're not careful, you could easily saw off your own leg, to say nothing of the fact that it's ugly and noisy and belches noxious fumes while you're using it, but that all provides a great deal of versatility and power that is rare in other languages.

    And yet, many professional carpenters prefer tools with guards, guides, cutoff switches, and other niceties over an unguided chainsaw. They prefer CRC milling machines over an expert artisan standing over a dremel tool all day, even though configuring the CRC machine sometimes has a long and painstaking setup and test process. Flexiblity is not the only good; although it is what's good about Perl.

    I think Perl is less like a chainsaw than a jigsaw with the ultimate cutting blade; it will cut through just about anything, including chewing up just about any guide you put on it, unless you're painstakingly careful about how you reign it in.

    Perl is good for flexible, freehand work. It's not a substitute for a bandsaw, drillpress, or lathe. It's much better tool for artists than for craftsmen.

Re: Principle of Inclusion
by Anonymous Monk on May 18, 2006 at 22:07 UTC
    if you're not careful, you could easily saw off your own leg, to say nothing of the fact that it's ugly and noisy and belches noxious fumes while you're using it, but that all provides a great deal of versatility and power that is rare in other languages.
    Could you clarify what you mean by "versatility and power"? Or maybe quantify what "rare" means. In the following list of languages, which are less versatile and less powerful...
    1. Python
    2. Ruby
    3. Lua
    4. Smalltalk
    5. Haskell
    6. ML
    7. Common Lisp
    8. Scheme
    9. Java
    10. C++
    11. C#
    12. Prolog
    13. Icon
    14. Erlang
    15. Rebol
    16. PHP
    17. JavaScript

      Sorry about the tardy reply. I was actually thinking about how to put my thoughts on the matter into words in the intervening period. The intent I tried to convey seemed so obvious from my perspective that I had to reorient a bit to see what needed to be explained. My failing, not yours.

      Basically, I'm not saying that languages having versatility and power (like Perl's) is necessarily rare. Rather, I'm saying that the sort of versatility and power you get with Perl (as opposed to types of versatility and power you don't get with Perl, like Ruby's excellent object model and the full range of Lisp macro capability) is generally rare in other languages. Language features like proper lexical closures (my favorite Perl toy these days) are not widely accessible in many other languages.

      Besides, there are a few languages out there that I wouldn't really call particularly "versatile" or "powerful" except within very narrow ranges of use, such as PHP, Javascript, and QBASIC.

      print substr("Just another Perl hacker", 0, -2);
      - apotheon
      CopyWrite Chad Perrin

Re: Principle of Inclusion
by swampyankee (Parson) on May 21, 2006 at 22:53 UTC

    Perl is powerful. So is VB, which is neither here nor there: any significantly useful programming language will give you quite enough rope to accidentally or deliberately hang yourself. Perl probably makes auto-hanging a tad more difficult than does C (or C++); some of the OO languages (Smalltalk, Eiffel) and functional languages (Haskell) probably make it more difficult still. A robust O/S -- and Windows is more robust than some people give it credit for being -- makes it more difficult for a language to hang random people in the neighborhood. Where Windows fails badly in the robustness department is that most users are logged on with administrator privileges; Windows (even XP) seems culturally wedded to the idea of being a single-user O/S. Non-administrative accounts are frequently unable to install software (any software), fonts, burn CD's, etc, which means that non-administrative accounts are too restricted to do much more than run Office and IE. The solution? Give them administrative privileges. Brilliant. It doesn't matter if the walls are reinforced concrete or papier maché when the doors are left open. This is where *ix descendants are clearly superior: Windows seems largely rooted in its past as an isolated, single user system; the *ix descendants evolved from a multi-user system.

    emc

    "Being forced to write comments actually improves code, because it is easier to fix a crock than to explain it. "
    —G. Steele
    A reply falls below the community's threshold of quality. You may see it by logging in.
A reply falls below the community's threshold of quality. You may see it by logging in.
A reply falls below the community's threshold of quality. You may see it by logging in.