First time here? We are a friendly community of Power Systems Engineers. Check out the FAQ!
You can put the code within a "1-loop" for loop and break out of it at different 'stages' (effectively jumping to the end):
for i in range(1):
![]() | 2 | No.2 Revision |
You can put the code within a "1-loop" for loop for-loop and break out of it at different 'stages' (effectively jumping to the end):end and not using quit() or sys.exit()):
# long code
code
for i in range(1):
range(1):
do something
if error1: break
do also...
if error2: break
...
and so on
# end of long code