On Wed, 13 Sep 2000, Greg Ewing wrote: > Fredrik Lundh <effbot@telia.com>: > > > "map(None, seq)" uses None to indicate that there are really > > no function to map things through. > > This one is just as controversial as print>>None. I would > argue that it *doesn't* mean "no function", because that > doesn't make sense -- there always has to be *some* function. > It really means "use a default function which constructs > a tuple from its arguments". Agreed. To take another example which I also find 'warty', string.split(foo, None, 3) doesn't mean "use no separators" it means "use whitespace separators which can't be defined in a single string". Thus, FWIW, I'm -1 on the >>None construct. I'll have a hard time teaching it, and I'll recommend against using it (unless and until convinced otherwise, of course). --david
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4