programa de salida de python
import sys
sys.exit()
cómo detener el programa en python
import sys
sys.exit()
script final de python
exit()
script de parada de python
some code
quit() # quit at this point
some more code (that's not executed)
script de parada de python
#Exit everywhere with error message
import sys
sys.exit("Code not Pythonical")
#Exit with a specific status
import os
os._exit()
#Exit in interpreter
quit()
#Exit in Interpreter but more user friendly
exit()
detener programa python
# Do stuff
stop = input("Would you like to stop the program? ")
if stop == "y":
exit()
else:
# do stuff