0
How to know the type of exception in python?
Is there any method to know the type of error. try: print(5/0) except ZeroDivisionError: print("Zero error occured:") try: name = "kevin" print(name/2) except Exception,e: error = str(e) #I saw this in Stackoverflow but this is not working print(e) Thanking you in advance <3
1 Resposta
0
Hii guys I using raise to know the type of error.
Is it good to use it???