James Mills prologic at shortcircuit.net.au
Sun Oct 19 05:44:02 CEST 2008

On Sun, Oct 19, 2008 at 1:30 PM, Steven D'Aprano
<steve at remove-this-cybersource.com.au> wrote:
> for x in (2**i for i in xrange(10)):
>    print x

This is by far the most concise solution I've seen so far.
And it should never be about conserving code.
Also, Python IS NOT C (to be more specific: Python
is not a C-class language).


-- "Problems are solved by method"

More information about the Python-list mailing list