[13131] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 541 Volume: 9

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sun Aug 15 10:17:21 1999

Date: Sun, 15 Aug 1999 07:10:13 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Sun, 15 Aug 1999     Volume: 9 Number: 541

Today's topics:
    Re: Why use Perl when we've got Python?! (Abigail)
    Re: Why use Perl when we've got Python?! (Abigail)
    Re: Why use Perl when we've got Python?! (Abigail)
    Re: Why use Perl when we've got Python?! <tchrist@mox.perl.com>
    Re: Why use Perl when we've got Python?! <tchrist@mox.perl.com>
    Re: Why use Perl when we've got Python?! <tchrist@mox.perl.com>
    Re: Why use Perl when we've got Python?! (Abigail)
    Re: Why use Perl when we've got Python?! (Abigail)
    Re: Why use Perl when we've got Python?! (Abigail)
    Re: Why use Python when we've got Perl? (Michael Rubenstein)
    Re: Win32 Perl (newbie) <cook@mediaone.net>
        Digest Administrivia (Last modified: 1 Jul 99) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: 15 Aug 1999 06:16:47 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <slrn7rd8eu.a5.abigail@alexandra.delanet.com>

John Stevens (jstevens@bamboo.verinet.com) wrote on MMCLXXIV September
MCMXCIII in <URL:news:slrn7r9lha.an4.jstevens@bamboo.verinet.com>:
?? On 13 Aug 1999 17:14:54 -0700, Tom Christiansen <tchrist@mox.perl.com> wrote:
?? 
?? >Perl, however, is perfectly consistent
?? >here across all assignment operations,
?? 
?? Wrong.

Don't say that again untill you've learned Perl.

?? Perl requires:
?? 
?? %hash = { "a" : 0 };

Why are you creating a hash with a list consisting of just one element?
Oh, I forgot. You don't know Perl.

?? in one spot, while in another:
?? 
?? %hash = { "a" => [ "silly", "stuff" ] };

You're making the same error again. I do fail to see what's
inconsistent though.

?? is required.  Perl is consistent in allocation, but this
?? is only because you only implement objects whose allocation
?? semantic can be polymorphically represented.  This is not
?? the case in Python.  Include a list type in Perl, then show
?? me both correct list semantics, *AND* consistent assignment
?? behavior.

Just for the hack of it. Assume there is a ``list type''. For the
sake of simplicity, assume '(:' and ':)' are the delimiters for
an anonymous list. Then your example would be:

   $hash = {a => (: "silly", "stuff" :)};

Quite logical, and in a similar fashion as anonymous arrays and hashes.
Of course, there isn't a list type, noone ever expresses the need for a
list type, there will never be a list type, and it doesn't have a meaning.




Abigail
-- 
%0=map{reverse+chop,$_}ABC,ACB,BAC,BCA,CAB,CBA;$_=shift().AC;1while+s/(\d+)((.)
(.))/($0=$1-1)?"$0$3$0{$2}1$2$0$0{$2}$4":"$3 => $4\n"/xeg;print#Towers of Hanoi


  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
   http://www.newsfeeds.com       The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including  Dedicated  Binaries Servers ==-----


------------------------------

Date: 15 Aug 1999 06:43:12 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <slrn7rda0c.a5.abigail@alexandra.delanet.com>

John Stevens (jstevens@bamboo.verinet.com) wrote on MMCLXXIV September
MCMXCIII in <URL:news:slrn7rb6eb.gr0.jstevens@bamboo.verinet.com>:
() On 14 Aug 1999 02:55:57 GMT, Sam Holden <sholden@pgrad.cs.usyd.edu.au> wrote:
() 
() Actually, the fact that I make such mistakes is part of my point:
() 
() I used Perl almost exclusively for a long time.  I left it for a
() short time, come back to it and . . .
() 
() Do you see my point?

Yes. You've made your point that you suck as a programmer very clear.

() Oh, I know Perl.  It's the syntax
() that I've managed to forget, and in a very short time.

Which says a lot about you, and nothing about Perl.

() I know you don't want to believe this, but that is also true of
() others.  And even the Perl coders around me have to make regular
() reference to "Quick Reference Cards".

We've seen your 4 line Python code. We've seen it not work. You would
also need the "Python Quick Reference Card". Just because you suck as
a programmer doesn't mean programming languages are bad.

() Thank you.  Do you see my point, though?  This is the second time
() I've taken a Perl-hiatus, and as you have pointed out, I no longer
() know Perl syntax.  Which means that I will, if I choose to continue
() using Perl, have to learn the language for the third time.
() 
() That is not cost effective.

Replace your memory.

() >Maybe python is, if so good on python, but that doesn't
() >reflect badly on perl.
() 
() What Python provides is not a language that idiots can use, but
() instead, it provides (among other things), more context.

context is a word not found in the index of "Learning Python".
Could you be more specific on what you mean?

() list.append( x ) is something that you can remember and understand
() even after years of being away, while ^$a.+ ((x[]) is not.  (No,
() that isn't Perl.  It's Kiss++.  But according to you Perl'ers, that
() statement ought to be "obvious"! ;-> )

Yeah, makes a lot of sense. A brain has dedicated cells to remember 
"append", while "push" just don't get stored.

() If Perl used, say:
() 
() hash.varName
() 
() or
() 
() hash:varName
() 
() or
() 
() hash&varName
() 
() instead of only a ASCII punctuation character, it would be less
() difficult to learn, easier to remember, and less confusing.  In
() other words, it would be more cost effective.

I don't get it. Are ``.'', ``:'' or ``&'' not ASCII punctutation
characters? And I guess you are refering to something like:

     $hash {varName}

which uses 3 punctuation characters, compared to Pythons:

      dict ["varName"]

that uses 33% more.

() If Perl used:
() 
() class
() 
() or
() 
() object
() 
() as a key word instead of
() 
() package
() 
() it would be less confusing.

But a package is more than a class. A class is a package, but not every
package is a class. 

() >If python wants the idiots then please find a way
() >to take them. I'll start recommending them from this day on.
() 
() Feel free.  I suspect that some of those people aren't idiots
() at all, they just have problem remembering that @$ means
() "a reference to an array".

That's probably because it doesn't mean that.


Abigail
-- 
perl -MTime::JulianDay -lwe'@r=reverse(M=>(0)x99=>CM=>(0)x399=>D=>(0)x99=>CD=>(
0)x299=>C=>(0)x9=>XC=>(0)x39=>L=>(0)x9=>XL=>(0)x29=>X=>IX=>0=>0=>0=>V=>IV=>0=>0
=>I=>$r=-2449231+gm_julian_day+time);do{until($r<$#r){$_.=$r[$#r];$r-=$#r}for(;
!$r[--$#r];){}}while$r;$,="\x20";print+$_=>September=>MCMXCIII=>()'


  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
   http://www.newsfeeds.com       The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including  Dedicated  Binaries Servers ==-----


------------------------------

Date: 15 Aug 1999 06:58:17 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <slrn7rdaso.a5.abigail@alexandra.delanet.com>

Chad Netzer (chad@vision.arc.nasa.gov) wrote on MMCLXXIV September
MCMXCIII in <URL:news:37B4E960.10BFB4DD@vision.arc.nasa.gov>:
__ 
__ PS.  I find Tom's Python criticisms a bit off base, at times,  but they
__ are mostly valid answers to the original question, and certainly not
__ inappropriate for c.l.perl.m.  However, Tom also has books to sell, and
__ that end is not achieved by turning people away from Perl.  Just
__ consider that when interpreting his criticisms.

That's a pretty lame remark, and if you know this group, you would know
it's totally unfounded. In fact, I know of more people that turned away
from Perl because they didn't like Tom than I know of people that got
dragged to Perl just because Tom tried to sell his books.

Of course, there are many people programming in Perl because they
read his excellent books.

Condsider yourself killfiled.


Abigail
-- 
perl -we '$@="\145\143\150\157\040\042\112\165\163\164\040\141\156\157\164".
             "\150\145\162\040\120\145\162\154\040\110\141\143\153\145\162".
             "\042\040\076\040\057\144\145\166\057\164\164\171";`$@`'


  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
   http://www.newsfeeds.com       The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including  Dedicated  Binaries Servers ==-----


------------------------------

Date: 15 Aug 1999 06:24:32 -0700
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <37b6b180@cs.colorado.edu>

     [courtesy cc of this posting mailed to cited author]

In comp.lang.perl.misc, m.faassen@vet.uu.nl (Martijn Faassen) quotes
me as writing:
:> gorilla@elaine.drink.com (Alan Barclay) writes:
:> :I personally gave up on python after wasting several hours trying to
:> :find a bug caused by incorrect indentation.
:> That's certainly a telling statement.

:I'm not a native speaker of English and I don't seem to be told; how is 
:it a telling statement?

I've heard of people spending hours trying to find the bug in C
code when they'd essentially written:

    while (condition)
	statement1;
	statement2;

Of

    if (condition) statement1; statement2;

These are of course because they forgot to embrace their block,
something C and most of its brethen permit (Perl excepted.)

I haven't personally heard many stories of people getting bitten by
a similar blocking-related issue in Python.  Now granted, that proves
little, as I do not spend my days living and breathing Python.  But the
existence proof suffice to show that the problem *can* occur, and that
people can actually have bugs and lost productivity because of it.
You can't tell from a purely anecdotal basis, but it's possible
that it occurs less in Python than in C.

Optional braces are a problem.  You can fix this one of two ways.
Perl chose one way by removing the optionality part:  Thou Shalt Embrace
the target of if/while/for statements, irrespective of the number
of statements.  Python chose a different way:  it removes the braces.
You must use indentation alone for indicate a set of target statements.
Somewhere in this somes the strange need for a "pass" statement
in python where none is needed in Perl.

    while (1) { }

becomes

    while 1:
	pass

Because even though Python permits a semi-colon a statement separator
or optional terminator,  it can't separate two "null statements".
These are illegal:

    while 1: ;

as well as

    while 1: 
	;

And annoyingly, so is this:

    if 1:
	# decomment the next line on a full moon
	# x = 1
    y = 20

Because, you see, that block has no statement now, which is illegal.

In Perl, this is just fine

    if (1) {
	# decomment the next line on a full moon
	# $x = 1
    } 
    $y = 20

--tom
-- 
"Morality is simply the attitude we adopt toward people whom we dislike"


------------------------------

Date: 15 Aug 1999 06:26:55 -0700
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <37b6b20f@cs.colorado.edu>

     [courtesy cc of this posting mailed to cited author]

In comp.lang.perl.misc, 
    m.faassen@vet.uu.nl (Martijn Faassen) writes:
:I still don't think the whitespace argument against
:Python is a good one. 

It may not be the strongest, but that doesn't mean it isn't there.

:Far better arguments exist; use those. :)

Try: "scope" :-)

--tom
-- 
    "Since nobody ever compared Hitler to Hitler, being compared with Hitler
    immediately disqualifies you for Hitlerhood." --Larry Wall


------------------------------

Date: 15 Aug 1999 06:38:47 -0700
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <37b6b4d7@cs.colorado.edu>

     [courtesy cc of this posting mailed to cited author]

In comp.lang.perl.misc, 
    abigail@delanet.com writes:
:Of course, Perl code doesn't change meaning if something (like IRC)
:strips leading whitespace (or collapses whitespace, like in HTML), Python
:code does. This is, in my opinion, the strongest argument against use
:of mandatory whitespace. 

Yup, try cutting and pasting Python code.  Very annoying.

It also makes it much harder to build up string to evaluate at run-time,
because they are subject to the same rules.  You have to be very careful
to get the white space right to pass into eval(), er, I mean exec().
Dagnammic, "exec" has a famous and well-defined meaning.  What *was*
he thinking?

--tom
-- 
"Software is like sex: It's better when it's free." (Linus Torvalds, from
FSF T-shirt)


------------------------------

Date: 15 Aug 1999 08:29:45 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <slrn7rdg88.a5.abigail@alexandra.delanet.com>

Tom Christiansen (tchrist@mox.perl.com) wrote on MMCLXXV September
MCMXCIII in <URL:news:37b61533@cs.colorado.edu>:
&&      [courtesy cc of this posting mailed to cited author]
&& 
&& In comp.lang.perl.misc, 
&&     abigail@delanet.com writes:
&& :So, $obj -> method () returns a scalar, right? And I call a method
&& :returning a list with @obj -> method (), right? And closures returning
&& :hashes are called like %closure -> (), right?
&& 
&& That doesn't even start to make sense.  The prefix deref binds more
&& tightly than the infix arrow.  When you want something else, you need
&& to specify grouping.


I know that, I was trying to point that what Kvav said didn't make sense.



Abigail
-- 
sub camel (^#87=i@J&&&#]u'^^s]#'#={123{#}7890t[0.9]9@+*`"'***}A&&&}n2o}00}t324i;
h[{e **###{r{+P={**{e^^^#'#i@{r'^=^{l+{#}H***i[0.9]&@a5`"':&^;&^,*&^$43##@@####;
c}^^^&&&k}&&&}#=e*****[]}'r####'`=437*{#};::'1[0.9]2@43`"'*#==[[.{{],,,1278@#@);
print+((($llama=prototype'camel')=~y|+{#}$=^*&[0-9]i@:;`"',.| |d)&&$llama."\n");


  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
   http://www.newsfeeds.com       The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including  Dedicated  Binaries Servers ==-----


------------------------------

Date: 15 Aug 1999 08:32:07 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <slrn7rdgcn.a5.abigail@alexandra.delanet.com>

Kevin Reid (kpreid@ibm.net) wrote on MMCLXXV September MCMXCIII in
<URL:news:1dwjpso.1du39emucuni0N@imac.loc>:
~~ 
~~ (BTW, after writing this, I'm thinking that this is actually an
~~ interesting and possibly useful way of producing encapsulation without
~~ having to write an object class.)


Ah, get my OO::Closures module from my directory on CPAN.


Abigail
-- 
package Z;use overload'""'=>sub{$b++?Hacker:Another};
sub TIESCALAR{bless\my$y=>Z}sub FETCH{$a++?Perl:Just}
$,=$";my$x=tie+my$y=>Z;print$y,$x,$y,$x,"\n";#Abigail


  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
   http://www.newsfeeds.com       The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including  Dedicated  Binaries Servers ==-----


------------------------------

Date: 15 Aug 1999 08:52:23 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Why use Perl when we've got Python?!
Message-Id: <slrn7rdhim.a5.abigail@alexandra.delanet.com>

Tom Christiansen (tchrist@mox.perl.com) wrote on MMCLXXV September
MCMXCIII in <URL:news:37b64372@cs.colorado.edu>:
!!      [courtesy cc of this posting mailed to cited author]
!! 
!! In comp.lang.perl.misc, 
!!     abigail@delanet.com writes:
!! :Really? I got my masters degree in CompSci without every writing a
!! :single C statement, without ever reading a single book on C, or getting
!! :any programming class in C. 
!! 
!! And how 'bout a job? :-)


I never had a job were programming in C was a requirement. I only did
once a 3 month project which ended in writing a demo in C. Oh, and it ran
fine on a Sun, but crashed on an HP, so it wasn't at all a good program.
That's all the significant C experience I have. Of course, for some silly
reason, our C programmers often come to me to ask for help....



Abigail
-- 
package Just_another_Perl_Hacker; sub print {($_=$_[0])=~ s/_/ /g;
                                      print } sub __PACKAGE__ { &
                                      print (     __PACKAGE__)} &
                                                  __PACKAGE__
                                            (                )


  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
   http://www.newsfeeds.com       The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including  Dedicated  Binaries Servers ==-----


------------------------------

Date: Sun, 15 Aug 1999 12:09:57 GMT
From: miker3@ix.netcom.com (Michael Rubenstein)
Subject: Re: Why use Python when we've got Perl?
Message-Id: <37b9a99b.635832158@nntp.ix.netcom.com>

On 14 Aug 1999 21:31:46 -0700, Tom Christiansen
<tchrist@mox.perl.com> wrote:

>Think back to the 80s and early 90s.  The change, if it really happened,
>came with the upty-gazillion CGI script kiddies who couldn't program
>2+2, yet who wanted *us* to write *them* these persistent, encrypted,
>crossplatform, multiscreen shopping carts for e-commerce, complete with
>dynamically-generated animated vanity counters, each and every time 
>they stepped up to the feeder.
>
>As a result, There's not much left of a spirit of a programming community
>of mutual benefit when it becomes numerically dominated by people who
>don't want to study or to work or EVEN TO PROGRAM, and who all seem to
>think you owe them something.

Anyone in comp.lang.python who is starting to feel sorry for the
beleaguered perl experts should read comp.lang.perl.misc.

Don't miss the thread (checking Perl offline) in which Tom goes
after one of these "CGI script kiddies" who has the audacity to
use the word "off-line" to mean not on the network and "upload"
to mean copy to the server (both usages are correct according to
the OED).

Make sure you check out the spelling and grammar from the
regulars.  Many of them are fond of insulting beginners for not
reading news.announce.newusers but feel free to ignore what the
announcements say about spelling and grammar flames.  Make sure
you check out the thread (Nastiness contrary to the spirit of
perl?) in which one of the regulars feels it necessary to attack
someone for using the word "ditto" to mean "I agree" (a
reasonable use of the word according to the OED).

Nor should you miss the current thread in which a number of
regulars register their reaction to Tom's harrassing someone with
email (HARASSMENT -- Monthly Autoemail) because Tom doesn't
approve of his method of quoting.

The problem in comp.lang.perl.misc is not the beginners -- it is
the regulars.


------------------------------

Date: Sun, 15 Aug 1999 07:25:47 -0400
From: edgar <cook@mediaone.net>
Subject: Re: Win32 Perl (newbie)
Message-Id: <37B6A3BB.C80391A4@mediaone.net>

James Liu wrote:

> I got Oreilly's Learning Perl (Llama book).  I'm running Windows 98.  what
> should I know about how perl runs on windows? please help.

After you install perl. I used ActivePerl then the best tutorial I found for
win9x was at  http://www.netcat.co.uk/rob/perl/win32perltut.html

Good luck
hth 'hope this helps'
-cookie




------------------------------

Date: 1 Jul 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 1 Jul 99)
Message-Id: <null>


Administrivia:

The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc.  For subscription or unsubscription requests, send
the single line:

	subscribe perl-users
or:
	unsubscribe perl-users

to almanac@ruby.oce.orst.edu.  

To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.

The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq" from
almanac@ruby.oce.orst.edu. The real FAQ, as it appeared last in the
newsgroup, can be retrieved with the request "send perl-users FAQ" from
almanac@ruby.oce.orst.edu. Due to their sizes, neither the Meta-FAQ nor
the FAQ are included in the digest.

The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq" from
almanac@ruby.oce.orst.edu. 

For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V9 Issue 541
*************************************


home help back first fref pref prev next nref lref last post