Re: Noob: Loops and the 'else' construct

2007-10-20 Thread Thorsten Kampe
* Dustan (Fri, 19 Oct 2007 11:39:04 -) On Oct 19, 3:12 am, Thorsten Kampe [EMAIL PROTECTED] wrote: So a for/else loop is exactly the same thing as a for loop with the else clause outside the loop (except for break)? Am I missing something here? It sounds to me like you just described

Re: Noob: Loops and the 'else' construct

2007-10-20 Thread Diez B. Roggisch
MRAB schrieb: On Oct 19, 4:11 am, Gabriel Genellina [EMAIL PROTECTED] wrote: En Thu, 18 Oct 2007 23:44:27 -0300, Ixiaus [EMAIL PROTECTED] escribió: I have just come across a site that discusses Python's 'for' and 'while' loops as having an (optional) 'else' structure. At first glance I

Re: Noob: Loops and the 'else' construct

2007-10-19 Thread MRAB
On Oct 19, 4:11 am, Gabriel Genellina [EMAIL PROTECTED] wrote: En Thu, 18 Oct 2007 23:44:27 -0300, Ixiaus [EMAIL PROTECTED] escribió: I have just come across a site that discusses Python's 'for' and 'while' loops as having an (optional) 'else' structure. At first glance I interpreted it

Re: Noob: Loops and the 'else' construct

2007-10-19 Thread Dustan
On Oct 19, 3:12 am, Thorsten Kampe [EMAIL PROTECTED] wrote: So a for/else loop is exactly the same thing as a for loop with the else clause outside the loop (except for break)? Am I missing something here? It sounds to me like you just described two identical constructs. Guess that's why I

Re: Noob: Loops and the 'else' construct

2007-10-19 Thread Thorsten Kampe
* Gabriel Genellina (Fri, 19 Oct 2007 00:11:18 -0300) En Thu, 18 Oct 2007 23:44:27 -0300, Ixiaus [EMAIL PROTECTED] escribió: I have just come across a site that discusses Python's 'for' and 'while' loops as having an (optional) 'else' structure. At first glance I interpreted it as

Re: Noob: Loops and the 'else' construct

2007-10-19 Thread Paul Boddie
On 19 Okt, 13:39, Dustan [EMAIL PROTECTED] wrote: On Oct 19, 3:12 am, Thorsten Kampe [EMAIL PROTECTED] wrote: So a for/else loop is exactly the same thing as a for loop with the else clause outside the loop (except for break)? Am I missing something here? It sounds to me like you just

Re: Noob: Loops and the 'else' construct

2007-10-18 Thread Gabriel Genellina
En Thu, 18 Oct 2007 23:44:27 -0300, Ixiaus [EMAIL PROTECTED] escribió: I have just come across a site that discusses Python's 'for' and 'while' loops as having an (optional) 'else' structure. At first glance I interpreted it as being a bit like the 'default' structure in PHP's switch

Noob: Loops and the 'else' construct

2007-10-18 Thread Ixiaus
I have just come across a site that discusses Python's 'for' and 'while' loops as having an (optional) 'else' structure. At first glance I interpreted it as being a bit like the 'default' structure in PHP's switch block... But the switch block isn't a loop, so, I am now confused as to the reason

Noob: Loops and the 'else' construct

2007-10-18 Thread Ixiaus
I have just come across a site that discusses Python's 'for' and 'while' loops as having an (optional) 'else' structure. At first glance I interpreted it as being a bit like the 'default' structure in PHP's switch block... But the switch block isn't a loop, so, I am now confused as to the reason