surprising result all (generator) (bug??)

MRAB python at mrabarnett.plus.com
Tue Jan 31 12:29:17 EST 2012


On 31/01/2012 12:40, Neal Becker wrote:
> I was just bitten by this unexpected behavior:
>
> In [24]: all ([i>  0 for i in xrange (10)])
> Out[24]: False
>
> In [25]: all (i>  0 for i in xrange (10))
> Out[25]: True
>
Which version of Python?



More information about the Python-list mailing list