Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Python by (47.6k points)

I am aware of the die() command in PHP which stops a script early.

How can I do this in Python?

1 Answer

0 votes
by (106k points)

You can use the sys library and exit() function for making exit program in python:-

import sys 

sys.exit()

Browse Categories

...