This thread moved to python-ideas so please post only there.
http://mail.python.org/pipermail/python-ideas/2009-October/005924.html
--yuv
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
Yuvgoog Greenle wrote:
When is the else after a loop executed?
> 1. When the loop isn't entered at all.
2. When the loop terminates through exhaustion of the list (does this
include when the list was empty?)
3. When the loop didn't exit because of a break statement.
1 and 3 are just special
On Wed, Sep 30, 2009 at 5:15 PM, Yuvgoog Greenle wrote:
> I like how python has a minimalistic and powerful syntax (-1 for the break
> ___ PEP).
> Also, I really dislike the for/else ambiguity "butterflies".
> When is the else after a loop executed? 1. When the loop isn't entered at
> all.
> 2. Wh
At 05:15 PM 9/30/2009, Yuvgoog Greenle wrote:
I like how python has a minimalistic and powerful syntax (-1 for the
break ___ PEP).
Also, I really dislike the for/else ambiguity "butterflies".
When is the else after a loop executed?
1. When the loop isn't entered at all.
2. When the loop termin
Yuvgoog Greenle wrote:
I like how python has a minimalistic and powerful syntax (-1 for the
break ___ PEP).
Also, I really dislike the for/else ambiguity "butterflies".
Properly understood, no ambiguity.
while c:
x()
is equivalent to hypothetical
label z:
if c:
x()
goto: z
So
while
Yuvgoog Greenle wrote:
I like how python has a minimalistic and powerful syntax (-1 for the
break ___ PEP).
Also, I really dislike the for/else ambiguity "butterflies".
When is the else after a loop executed?
1. When the loop isn't entered at all.
If you mean because the list / iterator is emp
I like how python has a minimalistic and powerful syntax (-1 for the break
___ PEP).
Also, I really dislike the for/else ambiguity "butterflies".
When is the else after a loop executed?1. When the loop isn't entered at
all.
2. When the loop terminates through exhaustion of the list (does this
inclu
On Tue, Sep 29, 2009 at 1:20 PM, Hatem Nassrat wrote:
> Tue Jul 3 10:14:17 CEST 2007, Guido van Rossum wrote:
>> On 6/30/07, Matt Chisholm wrote:
>> > I've created and submitted a new PEP proposing support for labels in
>> > Python's break and continue statements. Georg Brandl has graciously
>>
Tue Jul 3 10:14:17 CEST 2007, Guido van Rossum wrote:
> On 6/30/07, Matt Chisholm wrote:
> > I've created and submitted a new PEP proposing support for labels in
> > Python's break and continue statements. Georg Brandl has graciously
> > added it to the PEP list as PEP 3136:
> >
> > http://www.py