exist loop by pressing esc

John Gordon gordon at panix.com
Mon Oct 24 11:05:54 EDT 2016


In <6e030fd0-93c1-4d23-8656-e06c411b61aa at googlegroups.com> chris alindi <alindikris77 at gmail.com> writes:

> simple while loop range(10) if user press esc exits loop

range() is typically used with for loops, not while loops.

what is your while condition?
what use is the range() value?

-- 
John Gordon                   A is for Amy, who fell down the stairs
gordon at panix.com              B is for Basil, assaulted by bears
                                -- Edward Gorey, "The Gashlycrumb Tinies"




More information about the Python-list mailing list