Looping [was Re: Python and the need for speed]

Gregory Ewing greg.ewing at canterbury.ac.nz
Tue Apr 18 19:02:02 EDT 2017


Ben Bacarisse wrote:

> I fond the proportion on while True: loops surprising.  Is there
> something about Python that encourages that kind of loop?

Maybe because for-loops take care of most of the ordinary
cases in Python, leaving while-loops to cover the weird
ones, many of which need one or more exits in the middle
somewhere.

-- 
Greg



More information about the Python-list mailing list