Exit program

How can i exit from the

  • python
  • python in dynamo
  • C# code (this need probably exit from application - not from programm)?

1.) example for python code in dynamo - if list IN[0] is empty - exit programm or exit from code (its just try)

check_inn= **break** if not IN[0] else do it...

2.)or how apply GOTO in python for example (this need ignore/skip -this part of code - > do it…)

check_inn= **goto label 1** if not IN[0] else do it...

do it...

label 1:

OUT="done"

------ but in python 2.7 we cannot use this : from goto import with_goto