My python annoyances so far

Steve Holden steve at holdenweb.com
Thu Apr 26 08:13:20 EDT 2007


flifus at gmail.com wrote:
> Hi all. I'm learning python these days. I'm going to use this thread
> to post, from time to time, my annoyances with python. I hope someone
> will clarify things to me where I have misunderstood them.
> 
> Annoyances:
> 
> 1. Underscores! What's the deal with that? Especially those double
> underscores. The best answer I read on this is that the double
> underscores denotes special methods that the interpreter may
> automatically use. For example, 4+4 get expanded by the interpreter to
> 4.__add__(4).
> 
> 2. There are modules, there are functions, and there are classes-
> methods! Wouldn't it have been easier had everything either been a
> function or a class method?
> 
Actually, it's really simple. When you get right down to it, 
*everything* in *every* current implementation of Python is either a one 
or a zero. Would you like us to make it all zeros?

Perhaps you should meditate on the idea to the concept of "sufficient 
and necessary complexity" ...

If you're a beginning programmer then it might be that Python contains 
features you haven't yet needed. If you come from other languages (and 
there's a certain Java-ish feel to the second comment) then perhaps you 
aren't yet sufficiently familiar with Python to stop trying to write 
other languages in it. I know I gave up Java because, among other 
reasons, I found it tedious that I had to build a class method (and 
reference it) when what I really wanted was a function.

Finally, I think as a learner you *can* do the language a service by 
explaining what you find unnatural, inconvenient or incomprehensible. Do 
please realise though that many times things will be as they are for 
specific reasons, and sometimes even when the reasons aren't that good 
some people will argue for retaining the status quo.

Your posting actually reads quite like a letter to Viz - see

   http://www.viz.co.uk/

and follow the "Letterbocks" link - so it gave me a smile before I 
realised it was (probably) serious.

regards
  Steve
-- 
Steve Holden       +1 571 484 6266   +1 800 494 3119
Holden Web LLC/Ltd          http://www.holdenweb.com
Skype: holdenweb     http://del.icio.us/steve.holden
Recent Ramblings       http://holdenweb.blogspot.com




More information about the Python-list mailing list