Today's Question:  What does your personal desk look like?        GIVE A SHOUT

 ALL


  Python internals: adding a new statement to Python

This article is an attempt to better understand how the front-end of Python works. Just reading documentation and source code may be a bit boring, so I’m taking a hands-on approach here: I’m going to add an until statement to Python.All the coding for this article was done against the cutting-edge Py3k branch in the Python Mercurial repository mirror.The until statementSome languages, like Ruby, have an until statement, which is the complement to while (until num == 0 is equivalent to while num != 0). In Ruby, I can write:num = 3until num == 0 do puts num num -= 1endAnd it will...

2,306 0       PYTHON NEW STATEMENT RESEARCH ADDITION