Python - Custom Exceptions
Examine this code snippet:
What issue will arise when running this code?
class CustomError(Exception):
def __init__(self, msg):
self.msg = msg
try:
raise CustomError('Error occurred')
except CustomError as e:
print(e)What issue will arise when running this code?
