A single, general looping construct? (was: why no "do : until"?)

William Sonna wlsonna at attglobal.net
Fri Jan 5 21:33:00 EST 2001


On Fri, 5 Jan 2001 16:23:46, "Alex Martelli" <aleaxit at yahoo.com> 
wrote:

[snip]

> > So what's the deal with Python?
> 
> It's a general-purpose programming language, with no need for
> any special compatibility with existing ones. 

I was going to drop this, Alex, but I simply CAN'T let a statement 
like that go by unchallenged, so (with apologies).........

.......Since you haven't backed this seemingly sweeping statement up 
with any examples,  would you mind explaining what you mean by 
"special" compatibility?

> Having a general
> construct, introducing equivalent ones for several special
> cases would be unPythonic.  (You'll hear no Pythonista claim
> the re sublanguage is highly Pythonic, I'm sure -- particularly
> since it's basically identical to the Perl sublanguage that
> serves the same purpose:-).
> 
> 

1.  Wasn't the adoption Perl-style regex's essentially a tip of the 
hat to a widely used, widely understood (and refreshingly un-lippy) 
syntax?

2.  If convenience at the expense of redundancy trully has no place in
Python,  how do explain the likes of map, reduce and list 
comprehensions?  Are THEY not "special" instances of "while" with 
abbreviated syntax?

I submit that the ONLY practical purpose 1) or 2) serve is to produce 
cleaner (ie, less wordy) code.

They ARE, therefore, Miesian (Mies Van Der Rohe), or  minimalist, or 
Pythonic, if you prefer; DESPITE being redundant.



More information about the Python-list mailing list