stop script w/o exiting interpreter

Paul Rubin http
Thu Jan 25 18:01:27 EST 2007


"Alan Isaac" <aisaac at american.edu> writes:
> I'm fairly new to Python and I've lately been running a script at
> the interpreter while working on it.  Sometimes I only want to
> run the first quarter or half etc.  What is the "good" way to do this?

If it's single threaded then just call sys.exit().  If you don't know
what single threaded means, your program is definitely single threaded.



More information about the Python-list mailing list