Answers for "try catch python all exceptions"

3

python catch all exceptions

try:
    raise Exception("Oh no! An error happened!")
except Exception as err:
    print("An error was handled")
finally:
  	print("This runs either way.")
Posted by: Guest on March-20-2020

Code answers related to "try catch python all exceptions"

Python Answers by Framework

Browse Popular Code Answers by Language