0

My code look like this , it's not clear to me exit (0) and exit (other num). I give myself sometime but i didn't clear myself enough

from sys import exit
class Scene(object):
    def enter(self):
        print "This scene is not yet configured"
        exit(1)
Ivan Kolesnikov
  • 1,787
  • 1
  • 29
  • 45
squal
  • 185
  • 3
  • 14
  • It's the value returned by the program to the system. Usually, a value of 0 means "properly exited", and other values indicate a failure. –  May 29 '17 at 04:31
  • Hellow evert, you means it gives the error massage, right? – squal May 29 '17 at 04:35

1 Answers1

1

exit(0) means a clean exit without an error

exit(1) means there was an error and that is the reason for the exit

vvvvv
  • 25,404
  • 19
  • 49
  • 81