I come to praise .join, not to bury it...
Alex Martelli
aleaxit at yahoo.com
Wed Mar 7 04:01:01 EST 2001
"Mike C. Fletcher" <mcfletch at home.com> wrote in message
news:mailman.983928669.28324.python-list at python.org...
> Aesthetes are a different kind of professional, I'm a design theorist,
those
> are art wh#$3s ;) . Sorry, I dislike the connotations of "aesthete" (too
> turn of the last century eclecticism for me), so I use aesthetic (which, I
> feel, has a much nicer resonance with "ascetic", which is closer to my
sense
> of beauty).
Funny enough, that is also very close to what _I_, a mere engineer,
perceive as 'beauty': lack of decoration, match between form and
function, spareness, simplicity. As another 'engineer' put it,
perfection is reached, not when there's nothing more left to add,
but when there's nothing more left to be taken away (well, _almost_
an engineer -- he failed the examinations for his certificate --
although, as a pioneer of flight, he worked basically in the field
of engineering afterwards; maybe the epsilon of engineering he
lacked was the 'but practicality trumps purity' lithmus test...;-).
> I have no problem with the semantics of the string having methods. I
asked
> for lists and tuples to have a consistent and complete set of methods 2 or
3
> years ago if I'm recalling correctly. Healing the class/type split is
> something I would like to live to see (if the PSU doesn't get me first).
Indeed, such developments have contributed, and/or will/would
contribute, to the deep underlying beauty of the language in
the above-mentioned reference terms.
> I'll have to give that Python thing a try. Can you recommend any good
books
> for someone who's been stuck in a backwater language for the last 6 years?
My favourite books for Python beginners are:
"Learning Python", Mark Lutz & David Ascher, O'Reilly, 1-56592-464-9
"The Quick Python Book", Daryl Harms & Kenneth McDonald , Manning,
1-88477-774-0
They're not up-to-date to Python 2.0, I believe, but either will give
a good grounding on the fundamentals, and learning the 2.0/2.1 changes
on top of that is no biggie. Lutz & Ascher cover slowly, thoroughly,
and in depth, the language itself and the key parts of its libraries;
Harms & McDonald move faster, and cover (not quite as deeply) a wider
selection of topics. Choice between them is a matter of taste.
> Isn't that Python thing slow though? I heard they don't even have static
> type declarations and they don't support polymorphic function signature
> dispatches.
Python's polymorphism is by-method, not by 'function signature', but that's
hardly an issue of speed. As for speed, I find Python perfectly adequate
for my needs, with the proviso that some low-level performance bottlenecks
may have to be coded as extension modules -- of course, lots of such high
performance 'extensions' already exist, so, depending on your needs, you
may need no non-Python coding (e.g., for numeric operation on large arrays
and matrices, the Numeric extensions may already provide what you need).
> "," . join( ) doesn't help much, as there's no graphical connection drawn
> between the two items, so you lose the correspondence of the . character
to
> "member of" (i.e. the glyph no longer represents the concept, but must be
> interpreted at a semantic level to make the construct clear).
Personally, I find ','.join(blahblah) quite adequate -- if I had to
use double rather than single quotes, I would indeed see an epsilon's
worth of "loss" in visual terms.
Alex
More information about the Python-list
mailing list