language design question

Erik Max Francis max at alcyone.com
Sun Jul 9 20:16:05 EDT 2006


Steven D'Aprano wrote:

> On Sun, 09 Jul 2006 22:45:53 +0000, OKB (not okblacke) wrote:
> 
>> Terry Reedy wrote:
>>
>>> Consider
>>>>>> map(len, ('abc', (1,2,3), [1,2], {1:2}))
>>> [3, 3, 2, 1]
>>>
>>> Now try to rewrite this using methods (member functions).
>> [a.len() for a in ('abc', (1,2,3), [1,2], {1:2})]
> 
> Did you actually try that?

He was answering a hypothetical.  He wasn't suggesting that was valid 
syntax today.

-- 
Erik Max Francis && max at alcyone.com && http://www.alcyone.com/max/
  San Jose, CA, USA && 37 20 N 121 53 W && AIM erikmaxfrancis
   Don't try to confuse me with the facts.
    -- Bill McNeal



More information about the Python-list mailing list