why I don't like range/xrange

Bart Ogryczak B.Ogryczak at gmail.com
Fri Feb 16 12:01:42 EST 2007


On Feb 16, 4:30 pm, "stdazi" <std... at gmail.com> wrote:

> for (i = 0; some_function() /* or other condition */ ; i++)

C's "for(pre,cond,post) code" is nothing more, then shorthand form of
"pre; while(cond) {code; post;}"
Which translated to Python would be:

pre
while cond:
  code
  post






More information about the Python-list mailing list