[Python-Dev] Re: PEP 279 revisited (original) (raw)
Neal Norwitz neal@metaslash.com
Wed, 24 Apr 2002 08:26:03 -0400
- Previous message: [Python-Dev] Re: PEP 279 revisited
- Next message: [Python-Dev] Re: PEP 279 revisited
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
holger krekel wrote:
[discussion on naming enumerate() items()]
Additionally
items(dict)==dict.items() would be satisfied, so the analogy is better than 'rough'.
They are not equivalent, see below.
Neal
d = {10:20} print d.items() [(10, 20)] print enumerate(d) <enumerate object at 0x40208bcc> for x in enumerate(d): print x ... (0, 10)
- Previous message: [Python-Dev] Re: PEP 279 revisited
- Next message: [Python-Dev] Re: PEP 279 revisited
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]