[Python-Dev] Out-of-date FAQs
Aahz
aahz at pythoncraft.com
Tue Jan 4 01:13:14 CET 2005
On Tue, Jan 04, 2005, Delaney, Timothy C (Timothy) wrote:
>
> As a general rule, when an idiom has changed, do we want to state both
> the 2.4 idiom as well as the 2.3 idiom? In the case of list.sort(), that
> would mean having both:
>
> for key in sorted(dict.iterkeys()):
> ...do whatever with dict[key]...
>
> and
>
> keys = dict.keys()
> keys.sort()
> for key in keys:
> ...do whatever with dict[key]...
Yes. Until last July, the company I work for was still using 1.5.2.
Our current version is 2.2. I think that the FAQ should be usable for
anyone with a "reasonably current" version of Python, say at least two
major versions. IOW, answers should continue to work with 2.2 during
the lifetime of 2.4.
--
Aahz (aahz at pythoncraft.com) <*> http://www.pythoncraft.com/
"19. A language that doesn't affect the way you think about programming,
is not worth knowing." --Alan Perlis
More information about the Python-Dev
mailing list