Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>It's been present since the beginning. To see that, get the source from alt.sources, specifically the message titled "<a href="http://groups.google.com/group/alt.sources/browse_thread/thread/74a577bbcfc4be0a/cbaaec4fbfebbbb6" rel="noreferrer">Python 0.9.1 part 17/21</a>". The date is Feb 21, 1991. This post included the grammar definition, which states:</p> <pre><code>for_stmt: 'for' exprlist 'in' exprlist ':' suite ['else' ':' suite] </code></pre> <p>You might be able to find the 0.9.0 sources if you try harder than I did, but as the first public release was 0.9.0 on 20 Feb, that would get you back one day. The 0.9.1 release was a minor patch that did not affect this part of the grammar.</p> <p>(Is that a <a href="http://catb.org/jargon/html/U/UTSL.html" rel="noreferrer">UTSL</a> reference or what? When was the last time <em>you</em> looked at a shar file? ;)</p> <p>BTW, I reconstructed the original source and tweaked it a bit to compile under gcc-4.0 on my OS X 10.4 box. <a href="http://www.dalkescientific.com/writings/diary/archive/2009/03/27/python_0_9_1p1.html" rel="noreferrer">Details</a> for those interested few, including <a href="http://dalkescientific.com/Python/python-0.9.1.tar.gz" rel="noreferrer">python-0.9.1.tar.gz</a>.</p> <p>The entire development history is available from version control, even after changing version control systems twice. "hg log -p -r 6:7" from the cpython Mercurial archive shows that the "for/else" was committed on Sun Oct 14 12:07:46 1990 +0000, and the previous commit was Sat Oct 13 19:23:40 1990 +0000. for/else has been part of Python since October 1990. </p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload